~ionutbalutoiu/charms/trusty/neutron-api/next

« back to all changes in this revision

Viewing changes to hooks/charmhelpers/contrib/openstack/amulet/deployment.py

  • Committer: David Ames
  • Date: 2015-08-05 18:02:32 UTC
  • mfrom: (131 trunk)
  • mto: This revision was merged to the branch mainline in revision 148.
  • Revision ID: david.ames@canonical.com-20150805180232-ra2lmzuglf6rxnej
MergeĀ Upstream

Show diffs side-by-side

added added

removed removed

Lines of Context:
79
79
        services.append(this_service)
80
80
        use_source = ['mysql', 'mongodb', 'rabbitmq-server', 'ceph',
81
81
                      'ceph-osd', 'ceph-radosgw']
82
 
        # Openstack subordinate charms do not expose an origin option as that
83
 
        # is controlled by the principle
84
 
        ignore = ['neutron-openvswitch']
 
82
        # Most OpenStack subordinate charms do not expose an origin option
 
83
        # as that is controlled by the principle.
 
84
        ignore = ['cinder-ceph', 'hacluster', 'neutron-openvswitch']
85
85
 
86
86
        if self.openstack:
87
87
            for svc in services:
148
148
            return os_origin.split('%s-' % self.series)[1].split('/')[0]
149
149
        else:
150
150
            return releases[self.series]
 
151
 
 
152
    def get_ceph_expected_pools(self, radosgw=False):
 
153
        """Return a list of expected ceph pools in a ceph + cinder + glance
 
154
        test scenario, based on OpenStack release and whether ceph radosgw
 
155
        is flagged as present or not."""
 
156
 
 
157
        if self._get_openstack_release() >= self.trusty_kilo:
 
158
            # Kilo or later
 
159
            pools = [
 
160
                'rbd',
 
161
                'cinder',
 
162
                'glance'
 
163
            ]
 
164
        else:
 
165
            # Juno or earlier
 
166
            pools = [
 
167
                'data',
 
168
                'metadata',
 
169
                'rbd',
 
170
                'cinder',
 
171
                'glance'
 
172
            ]
 
173
 
 
174
        if radosgw:
 
175
            pools.extend([
 
176
                '.rgw.root',
 
177
                '.rgw.control',
 
178
                '.rgw',
 
179
                '.rgw.gc',
 
180
                '.users.uid'
 
181
            ])
 
182
 
 
183
        return pools