]> review.fuel-infra Code Review - openstack-build/cinder-build.git/commitdiff
Improve cinder packages 61/10061/7
authorMikhail Ivanov <mivanov@mirantis.com>
Tue, 4 Aug 2015 09:48:44 +0000 (12:48 +0300)
committerMikhail Ivanov <mivanov@mirantis.com>
Wed, 5 Aug 2015 17:22:56 +0000 (20:22 +0300)
  * Fix build and runtime dependencies
  * Fix files installation

Change-Id: If354bb8036bb9f703341f8d659014b970e95d6ed
Closes-Bug: #1462246

trusty/debian/changelog
trusty/debian/cinder-common.install
trusty/debian/cinder-common.postinst
trusty/debian/cinder.conf [deleted file]
trusty/debian/control
trusty/debian/copyright
trusty/debian/rules

index 79c7a74cc73cb38adba79282867553e544750a22..a38de631b7de70ba92edbf33ac4269cd679d9efe 100644 (file)
@@ -1,3 +1,11 @@
+cinder (1:2015.1.0-1~u14.04+mos6) mos7.0; urgency=medium
+
+  * Fix build and runtime dependencies
+  * Fix files installation
+    LP#1462246
+
+ -- Mikhail Ivanov <mivanov@mirantis.com>  Tue, 04 Aug 2015 12:37:59 +0300
+
 cinder (1:2015.1.0-1~u14.04+mos5) mos7.0; urgency=medium
 
   * debian/control:
index 0269adf17c46264be2fc4fa2d6e227df541e5683..d9d3e8456e45696be8fca2631da09dc527030c57 100644 (file)
@@ -1,6 +1,3 @@
-debian/cinder.conf etc/cinder
-debian/cinder_sudoers etc/sudoers.d
-debian/logging.conf etc/cinder
 etc/cinder/api-paste.ini etc/cinder
 etc/cinder/policy.json etc/cinder
 etc/cinder/rootwrap.conf etc/cinder
index 0c89129eb6d47a5ad2df61cd25eda6a97d15dd4d..3fa8dbc1b8082656f3d5cd9bbaa1a232ca781050 100644 (file)
@@ -7,18 +7,88 @@ if [ "$1" = "configure" ]; then
 
     if ! getent passwd cinder > /dev/null 2>&1; then
         adduser --system --home /var/lib/cinder --ingroup cinder --no-create-home \
-            --shell /bin/false cinder
+            --shell /usr/sbin/nologin cinder
     fi
 
     chown -R cinder:adm /var/log/cinder
     chmod 0750 /var/log/cinder
     chown -R cinder:cinder /var/lib/cinder /etc/cinder
     chmod 0750 /etc/cinder
-    chmod 0440 /etc/sudoers.d/cinder_sudoers
     chown -R root:root /etc/cinder/rootwrap.d
     chmod 0755 /etc/cinder/rootwrap.d
     chown root:root /etc/cinder/rootwrap.conf
 
+    # generating cinder.conf.sample
+    python -m cinder.openstack.common.config.generator cinder/api/common.py cinder/api/middleware/auth.py \
+        cinder/api/middleware/sizelimit.py cinder/api/views/versions.py \
+        cinder/backup/chunkeddriver.py cinder/backup/driver.py \
+        cinder/backup/drivers/ceph.py cinder/backup/drivers/nfs.py \
+        cinder/backup/drivers/swift.py cinder/backup/drivers/tsm.py \
+        cinder/backup/manager.py cinder/cmd/manage.py cinder/cmd/volume.py \
+        cinder/cmd/volume_usage_audit.py cinder/common/config.py \
+        cinder/compute/__init__.py cinder/compute/nova.py cinder/db/api.py \
+        cinder/db/base.py cinder/exception.py cinder/image/glance.py \
+        cinder/image/image_utils.py cinder/keymgr/conf_key_mgr.py \
+        cinder/keymgr/__init__.py cinder/keymgr/key_mgr.py \
+        cinder/openstack/common/eventlet_backdoor.py \
+        cinder/openstack/common/periodic_task.py \
+        cinder/openstack/common/policy.py \
+        cinder/openstack/common/versionutils.py cinder/quota.py \
+        cinder/scheduler/driver.py cinder/scheduler/host_manager.py \
+        cinder/scheduler/manager.py cinder/scheduler/scheduler_options.py \
+        cinder/scheduler/simple.py cinder/scheduler/weights/capacity.py \
+        cinder/scheduler/weights/volume_number.py cinder/service.py \
+        cinder/ssh_utils.py cinder/transfer/api.py cinder/volume/api.py \
+        cinder/volume/driver.py cinder/volume/drivers/block_device.py \
+        cinder/volume/drivers/cloudbyte/options.py \
+        cinder/volume/drivers/datera.py \
+        cinder/volume/drivers/dell/dell_storagecenter_common.py \
+        cinder/volume/drivers/emc/emc_vmax_common.py \
+        cinder/volume/drivers/emc/emc_vnx_cli.py \
+        cinder/volume/drivers/emc/xtremio.py cinder/volume/drivers/eqlx.py \
+        cinder/volume/drivers/glusterfs.py cinder/volume/drivers/hds/hds.py \
+        cinder/volume/drivers/hds/iscsi.py cinder/volume/drivers/hds/nfs.py \
+        cinder/volume/drivers/hitachi/hbsd_common.py \
+        cinder/volume/drivers/hitachi/hbsd_fc.py \
+        cinder/volume/drivers/hitachi/hbsd_horcm.py \
+        cinder/volume/drivers/hitachi/hbsd_iscsi.py \
+        cinder/volume/drivers/huawei/__init__.py \
+        cinder/volume/drivers/ibm/flashsystem.py cinder/volume/drivers/ibm/gpfs.py \
+        cinder/volume/drivers/ibm/ibmnas.py \
+        cinder/volume/drivers/ibm/storwize_svc/__init__.py \
+        cinder/volume/drivers/ibm/xiv_ds8k.py cinder/volume/drivers/lvm.py \
+        cinder/volume/drivers/netapp/options.py cinder/volume/drivers/nfs.py \
+        cinder/volume/drivers/nimble.py cinder/volume/drivers/openvstorage.py \
+        cinder/volume/drivers/prophetstor/options.py cinder/volume/drivers/pure.py \
+        cinder/volume/drivers/quobyte.py cinder/volume/drivers/rbd.py \
+        cinder/volume/drivers/remotefs.py \
+        cinder/volume/drivers/san/hp/hp_3par_common.py \
+        cinder/volume/drivers/san/hp/hp_lefthand_rest_proxy.py \
+        cinder/volume/drivers/san/san.py cinder/volume/drivers/scality.py \
+        cinder/volume/drivers/smbfs.py cinder/volume/drivers/solidfire.py \
+        cinder/volume/drivers/srb.py cinder/volume/drivers/violin/v6000_common.py \
+        cinder/volume/drivers/vmware/vmdk.py cinder/volume/drivers/windows/windows.py \
+        cinder/volume/drivers/xio.py cinder/volume/drivers/zfssa/zfssanfs.py \
+        cinder/volume/manager.py cinder/wsgi.py \
+        cinder/zonemanager/drivers/brocade/brcd_fabric_opts.py \
+        cinder/zonemanager/drivers/brocade/brcd_fc_zone_driver.py \
+        cinder/zonemanager/drivers/cisco/cisco_fabric_opts.py \
+        cinder/zonemanager/drivers/cisco/cisco_fc_zone_driver.py cinder/zonemanager/fc_zone_manager.py \
+        > /etc/cinder/cinder.conf.sample && \
+
+        oslo-config-generator \
+        --namespace oslo_concurrency --namespace oslo_db \
+        --namespace oslo_messaging --namespace policy \
+        --namespace keystonemiddleware.auth_token  >> /etc/cinder/cinder.conf.sample
+
+    if [ "$?" -ne 0 ]; then
+        echo "cinder configuration file generation fails!"
+    fi
+
+    if [ ! -f "/etc/cinder/cinder.conf" ]; then
+        cp /etc/cinder/cinder.conf.sample /etc/cinder/cinder.conf
+    fi
+
     if [ -e /var/lib/cinder/cinder.sqlite ]; then
         chown cinder:cinder /var/lib/cinder/cinder.sqlite
         chmod 0600 /var/lib/cinder/cinder.sqlite
diff --git a/trusty/debian/cinder.conf b/trusty/debian/cinder.conf
deleted file mode 100644 (file)
index 7094033..0000000
+++ /dev/null
@@ -1,11 +0,0 @@
-[DEFAULT]
-rootwrap_config = /etc/cinder/rootwrap.conf
-api_paste_confg = /etc/cinder/api-paste.ini
-iscsi_helper = tgtadm
-volume_name_template = volume-%s
-volume_group = cinder-volumes
-verbose = True
-auth_strategy = keystone
-state_path = /var/lib/cinder
-lock_path = /var/lock/cinder
-volumes_dir = /var/lib/cinder/volumes
index 3a5f9a683a7814b2f1564a5efcf8364dff576842..0fa58ea35d2595899e0c5e48e26b07c3eb533624 100644 (file)
@@ -5,8 +5,11 @@ Maintainer: MOS Cinder Team <mos-cinder@mirantis.com>
 Build-Depends:
  debhelper (>= 9),
  dh-systemd,
+ dh-python,
  openstack-pkg-tools (>= 21),
  python-all (>= 2.7.1),
+ python-pbr (>= 0.10),
+ python-setuptools,
  python-sphinx (>= 1.1.2)
 Build-Depends-Indep:
  python-anyjson (>= 0.3.3),
@@ -48,7 +51,6 @@ Build-Depends-Indep:
  python-paramiko (>= 1.13.0),
  python-paste,
  python-pastedeploy (>= 1.5.0),
- python-pbr (>= 0.10),
  python-psycopg2,
  python-pyparsing (>= 2.0.1),
  python-requests (>= 2.2.0),
@@ -79,15 +81,16 @@ Depends:
  python-anyjson (>= 0.3.3),
  python-babel (>= 1.3),
  python-barbicanclient (>= 3.0.1),
+ python-ceph,
  python-crypto (>= 2.6),
  python-eventlet (>= 0.16.1),
  python-glanceclient (>= 1:0.15.0),
  python-greenlet (>= 0.3.2),
+ python-hp3parclient,
  python-iso8601 (>= 0.1.9),
  python-keystoneclient (>= 1:1.1.0),
  python-keystonemiddleware (>= 1.5.0),
  python-kombu (>= 2.5.0),
- python-lockfile (>= 1:0.8),
  python-lxml (>= 2.3),
  python-migrate (>= 0.9.5),
  python-netaddr (>= 0.7.12),
@@ -113,6 +116,7 @@ Depends:
  python-requests (>= 2.2.0),
  python-retrying (>= 1.2.3),
  python-routes (>= 1.12.3),
+ python-rtslib-fb,
  python-six (>= 1.9.0),
  python-sqlalchemy (>= 0.9.7),
  python-stevedore (>= 1.3.0),
@@ -122,7 +126,6 @@ Depends:
  python-webob (>= 1.2.3),
  ${misc:Depends},
  ${python:Depends}
-Suggests: python-ceph, python-hp3parclient, python-rtslib-fb
 Description: Cinder Python libraries
  OpenStack is a reliable cloud infrastructure. Its mission is to produce
  the ubiquitous cloud computing platform that will meet the needs of public
index 9d7959a8de73bdc5fb4760ad08bd9c78066c7f31..2902979fb0cce7c2a16eb9e17efdd47d523c1cf0 100644 (file)
@@ -1,13 +1,22 @@
 Format: http://dep.debian.net/deps/dep5-
-Upstream-Name: nova
-Source: https://code.launchpad.net/nova
+Upstream-Name: cinder
+Source: git://github.com/openstack/cinder.git
+
+Files: debian/*
+Copyright: 2011-2013, Thomas Goirand <zigo@debian.org>
+          2014, Vasyl Saienko <vsaienko@mirantis.com>
+          2014, Maksym Yatsenko <myatsenko@mirantis.com>
+           2015, Mikhail Ivanov <mivanov@mirantis.com>
+License: Apache-2
 
 Files: *
 Copyright: 2010 United States Government as represented
                 by the Administrator of the National Aeronautics
                 and Space Administration.
-Copyright: 2010 OpenStack LLC
-Copyright: Others (See individual files for more details)
+          2010 OpenStack LLC
+               Others (See individual files for more details)
+License: Apache-2
+
 License: Apache-2
  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
index 2222f4f2b8abc7efd4d9e63d6a6058a2deb55ea7..82fe7bad01468e9262db4c5f1aba273ae0ac6e1f 100755 (executable)
@@ -20,9 +20,12 @@ endif
 
 override_dh_install:
        dh_install --fail-missing -Xbin/cinder-all
+       install -D -m 0440 debian/cinder_sudoers $(CURDIR)/debian/cinder-common/etc/sudoers.d/cinder-common
+       install -D -m 0644 $(CURDIR)/debian/logging.conf $(CURDIR)/debian/cinder-common/etc/cinder/logging.conf
 
 override_dh_fixperms:
        dh_fixperms -Xcinder_tgt.conf
+       chmod 0440 $(CURDIR)/debian/cinder-common/etc/sudoers.d/cinder-common
 
 override_dh_clean:
        # temporary workaround for d2to1 wonkyness