diff -Nru magnum-9.0.0~rc1/ChangeLog magnum-9.0.0/ChangeLog --- magnum-9.0.0~rc1/ChangeLog 2019-09-27 17:14:08.000000000 +0000 +++ magnum-9.0.0/ChangeLog 2019-10-16 12:40:50.000000000 +0000 @@ -1,6 +1,13 @@ CHANGES ======= +9.0.0 +----- + +* Propagate cloud\_provider\_enabled correctly +* Update .gitreview for stable/train +* ci: Add output stream fixture to fix CI + 9.0.0.0rc1 ---------- diff -Nru magnum-9.0.0~rc1/debian/changelog magnum-9.0.0/debian/changelog --- magnum-9.0.0~rc1/debian/changelog 2019-09-27 20:54:36.000000000 +0000 +++ magnum-9.0.0/debian/changelog 2019-10-16 18:14:21.000000000 +0000 @@ -1,8 +1,14 @@ -magnum (9.0.0~rc1-0ubuntu1~cloud0) bionic-train; urgency=medium +magnum (9.0.0-0ubuntu1~cloud0) bionic-train; urgency=medium - * New update for the Ubuntu Cloud Archive. + * New upstream release for the Ubuntu Cloud Archive. - -- Openstack Ubuntu Testing Bot Fri, 27 Sep 2019 20:54:36 +0000 + -- Openstack Ubuntu Testing Bot Wed, 16 Oct 2019 18:14:21 +0000 + +magnum (9.0.0-0ubuntu1) eoan; urgency=medium + + * New stable point release for OpenStack Train. + + -- Sahid Orentino Ferdjaoui Wed, 16 Oct 2019 17:30:57 +0100 magnum (9.0.0~rc1-0ubuntu1) eoan; urgency=medium diff -Nru magnum-9.0.0~rc1/doc/source/user/index.rst magnum-9.0.0/doc/source/user/index.rst --- magnum-9.0.0~rc1/doc/source/user/index.rst 2019-09-27 17:12:32.000000000 +0000 +++ magnum-9.0.0/doc/source/user/index.rst 2019-10-16 12:38:11.000000000 +0000 @@ -386,7 +386,7 @@ | `cgroup_driver`_ | - systemd | "cgroupfs" | | | - cgroupfs | | +---------------------------------------+--------------------+---------------+ -| `cloud_provider_enabled`_ | - true | true | +| `cloud_provider_enabled`_ | - true | see below | | | - false | | +---------------------------------------+--------------------+---------------+ | `service_cluster_ip_range` | IPv4 CIDR for k8s | 10.254.0.0/16 | @@ -1284,9 +1284,12 @@ _`cloud_provider_enabled` Add 'cloud_provider_enabled' label for the k8s_fedora_atomic driver. Defaults - to true. For specific kubernetes versions if 'cinder' is selected as a - 'volume_driver', it is implied that the cloud provider will be enabled since - they are combined. + to the value of 'cluster_user_trust' (default: 'false' unless explicitly set + to 'true' in magnum.conf due to CVE-2016-7404). Consequently, + 'cloud_provider_enabled' label cannot be overridden to 'true' when + 'cluster_user_trust' resolves to 'false'. For specific kubernetes versions, + if 'cinder' is selected as a 'volume_driver', it is implied that the cloud + provider will be enabled since they are combined. _`keystone_auth_enabled` If this label is set to True, Kubernetes will support use Keystone for diff -Nru magnum-9.0.0~rc1/magnum/drivers/heat/k8s_fedora_template_def.py magnum-9.0.0/magnum/drivers/heat/k8s_fedora_template_def.py --- magnum-9.0.0~rc1/magnum/drivers/heat/k8s_fedora_template_def.py 2019-09-27 17:12:32.000000000 +0000 +++ magnum-9.0.0/magnum/drivers/heat/k8s_fedora_template_def.py 2019-10-16 12:38:17.000000000 +0000 @@ -108,17 +108,18 @@ # the cloud provider needs to be enabled. cloud_provider_enabled = cluster.labels.get( 'cloud_provider_enabled', - 'true' if CONF.trust.cluster_user_trust else 'false').lower() + 'true' if CONF.trust.cluster_user_trust else 'false') if (not CONF.trust.cluster_user_trust - and cloud_provider_enabled == 'true'): + and cloud_provider_enabled.lower() == 'true'): raise exception.InvalidParameterValue(_( '"cluster_user_trust" must be set to True in magnum.conf when ' '"cloud_provider_enabled" label is set to true.')) if (cluster_template.volume_driver == 'cinder' - and cloud_provider_enabled == 'false'): + and cloud_provider_enabled.lower() == 'false'): raise exception.InvalidParameterValue(_( '"cinder" volume driver needs "cloud_provider_enabled" label ' 'to be true or unset.')) + extra_params['cloud_provider_enabled'] = cloud_provider_enabled extra_params['master_image'] = cluster_template.image_id extra_params['minion_image'] = cluster_template.image_id @@ -130,7 +131,7 @@ 'calico_tag', 'calico_kube_controllers_tag', 'calico_ipv4pool', 'etcd_tag', 'flannel_tag', 'flannel_cni_tag', - 'cloud_provider_enabled', 'cloud_provider_tag', + 'cloud_provider_tag', 'prometheus_tag', 'grafana_tag', 'heat_container_agent_tag', 'keystone_auth_enabled', 'k8s_keystone_auth_tag', diff -Nru magnum-9.0.0~rc1/magnum/drivers/k8s_fedora_atomic_v1/templates/kubecluster.yaml magnum-9.0.0/magnum/drivers/k8s_fedora_atomic_v1/templates/kubecluster.yaml --- magnum-9.0.0~rc1/magnum/drivers/k8s_fedora_atomic_v1/templates/kubecluster.yaml 2019-09-27 17:12:32.000000000 +0000 +++ magnum-9.0.0/magnum/drivers/k8s_fedora_atomic_v1/templates/kubecluster.yaml 2019-10-16 12:38:17.000000000 +0000 @@ -382,7 +382,6 @@ cloud_provider_enabled: type: boolean description: Enable or disable the openstack kubernetes cloud provider - default: true etcd_tag: type: string diff -Nru magnum-9.0.0~rc1/magnum/tests/base.py magnum-9.0.0/magnum/tests/base.py --- magnum-9.0.0~rc1/magnum/tests/base.py 2019-09-27 17:12:28.000000000 +0000 +++ magnum-9.0.0/magnum/tests/base.py 2019-10-16 12:38:11.000000000 +0000 @@ -30,6 +30,7 @@ from magnum.objects import base as objects_base from magnum.tests import conf_fixture from magnum.tests import fake_notifier +from magnum.tests import output_fixture from magnum.tests import policy_fixture @@ -79,6 +80,8 @@ self.policy = self.useFixture(policy_fixture.PolicyFixture()) + self.output = self.useFixture(output_fixture.OutputStreamCapture()) + self.useFixture(fixtures.MockPatchObject( oslo_messaging, 'Notifier', fake_notifier.FakeNotifier)) diff -Nru magnum-9.0.0~rc1/magnum/tests/output_fixture.py magnum-9.0.0/magnum/tests/output_fixture.py --- magnum-9.0.0~rc1/magnum/tests/output_fixture.py 1970-01-01 00:00:00.000000000 +0000 +++ magnum-9.0.0/magnum/tests/output_fixture.py 2019-10-16 12:38:11.000000000 +0000 @@ -0,0 +1,48 @@ +# Copyright 2010 United States Government as represented by the +# Administrator of the National Aeronautics and Space Administration. +# All Rights Reserved. +# +# Licensed under the Apache License, Version 2.0 (the "License"); you may +# not use this file except in compliance with the License. You may obtain +# a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT +# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the +# License for the specific language governing permissions and limitations +# under the License. + +import fixtures +import os + +_TRUE_VALUES = ('True', 'true', '1', 'yes') + + +class OutputStreamCapture(fixtures.Fixture): + """Capture output streams during tests. + + This fixture captures errant printing to stderr / stdout during + the tests and lets us see those streams at the end of the test + runs instead. Useful to see what was happening during failed + tests. + """ + def setUp(self): + super(OutputStreamCapture, self).setUp() + if os.environ.get('OS_STDOUT_CAPTURE') in _TRUE_VALUES: + self.out = self.useFixture(fixtures.StringStream('stdout')) + self.useFixture( + fixtures.MonkeyPatch('sys.stdout', self.out.stream)) + if os.environ.get('OS_STDERR_CAPTURE') in _TRUE_VALUES: + self.err = self.useFixture(fixtures.StringStream('stderr')) + self.useFixture( + fixtures.MonkeyPatch('sys.stderr', self.err.stream)) + + @property + def stderr(self): + return self.err._details["stderr"].as_text() + + @property + def stdout(self): + return self.out._details["stdout"].as_text() diff -Nru magnum-9.0.0~rc1/magnum/tests/unit/conductor/handlers/test_k8s_cluster_conductor.py magnum-9.0.0/magnum/tests/unit/conductor/handlers/test_k8s_cluster_conductor.py --- magnum-9.0.0~rc1/magnum/tests/unit/conductor/handlers/test_k8s_cluster_conductor.py 2019-09-27 17:12:32.000000000 +0000 +++ magnum-9.0.0/magnum/tests/unit/conductor/handlers/test_k8s_cluster_conductor.py 2019-10-16 12:38:17.000000000 +0000 @@ -290,6 +290,7 @@ 'insecure_registry': '10.0.0.1:5000', } expected = { + 'cloud_provider_enabled': 'false', 'ssh_key_name': 'keypair_id', 'external_network': 'e2a6c8b0-a3c2-42a3-b3f4-01400a30896e', 'fixed_network': 'fixed_network', @@ -432,6 +433,7 @@ expected = { 'auth_url': 'http://192.168.10.10:5000/v3', + 'cloud_provider_enabled': 'true', 'cluster_uuid': '5d12f6fd-a196-4bf0-ae4c-1f639a523a52', 'discovery_url': 'https://discovery.etcd.io/test', 'dns_nameserver': 'dns_nameserver', @@ -567,6 +569,7 @@ expected = { 'auth_url': 'http://192.168.10.10:5000/v3', + 'cloud_provider_enabled': 'false', 'cluster_uuid': '5d12f6fd-a196-4bf0-ae4c-1f639a523a52', 'discovery_url': 'https://discovery.etcd.io/test', 'docker_volume_size': 20, @@ -994,6 +997,7 @@ cluster) expected = { + 'cloud_provider_enabled': 'false', 'ssh_key_name': 'keypair_id', 'external_network': 'e2a6c8b0-a3c2-42a3-b3f4-01400a30896e', 'fixed_network': 'fixed_network', diff -Nru magnum-9.0.0~rc1/magnum.egg-info/pbr.json magnum-9.0.0/magnum.egg-info/pbr.json --- magnum-9.0.0~rc1/magnum.egg-info/pbr.json 2019-09-27 17:14:08.000000000 +0000 +++ magnum-9.0.0/magnum.egg-info/pbr.json 2019-10-16 12:40:50.000000000 +0000 @@ -1 +1 @@ -{"git_version": "a0c894a2", "is_release": true} \ No newline at end of file +{"git_version": "5e66b4fe", "is_release": true} \ No newline at end of file diff -Nru magnum-9.0.0~rc1/magnum.egg-info/PKG-INFO magnum-9.0.0/magnum.egg-info/PKG-INFO --- magnum-9.0.0~rc1/magnum.egg-info/PKG-INFO 2019-09-27 17:14:08.000000000 +0000 +++ magnum-9.0.0/magnum.egg-info/PKG-INFO 2019-10-16 12:40:50.000000000 +0000 @@ -1,6 +1,6 @@ Metadata-Version: 2.1 Name: magnum -Version: 9.0.0.0rc1 +Version: 9.0.0 Summary: Container Management project for OpenStack Home-page: http://docs.openstack.org/magnum/latest/ Author: OpenStack diff -Nru magnum-9.0.0~rc1/magnum.egg-info/SOURCES.txt magnum-9.0.0/magnum.egg-info/SOURCES.txt --- magnum-9.0.0~rc1/magnum.egg-info/SOURCES.txt 2019-09-27 17:14:08.000000000 +0000 +++ magnum-9.0.0/magnum.egg-info/SOURCES.txt 2019-10-16 12:40:51.000000000 +0000 @@ -687,6 +687,7 @@ magnum/tests/conf_fixture.py magnum/tests/fake_notifier.py magnum/tests/fakes.py +magnum/tests/output_fixture.py magnum/tests/policy_fixture.py magnum/tests/utils.py magnum/tests/contrib/copy_instance_logs.sh diff -Nru magnum-9.0.0~rc1/PKG-INFO magnum-9.0.0/PKG-INFO --- magnum-9.0.0~rc1/PKG-INFO 2019-09-27 17:14:09.000000000 +0000 +++ magnum-9.0.0/PKG-INFO 2019-10-16 12:40:51.000000000 +0000 @@ -1,6 +1,6 @@ Metadata-Version: 2.1 Name: magnum -Version: 9.0.0.0rc1 +Version: 9.0.0 Summary: Container Management project for OpenStack Home-page: http://docs.openstack.org/magnum/latest/ Author: OpenStack diff -Nru magnum-9.0.0~rc1/tox.ini magnum-9.0.0/tox.ini --- magnum-9.0.0~rc1/tox.ini 2019-09-27 17:12:28.000000000 +0000 +++ magnum-9.0.0/tox.ini 2019-10-16 12:38:11.000000000 +0000 @@ -13,6 +13,8 @@ setenv = VIRTUAL_ENV={envdir} PYTHONWARNINGS=default::DeprecationWarning + OS_STDOUT_CAPTURE=1 + OS_STDERR_CAPTURE=1 deps = -r{toxinidir}/requirements.txt -r{toxinidir}/test-requirements.txt passenv = TEMPEST_* OS_TEST_*