We are ecstatic to announce the release of: zun 0.2.0: Container Management service for OpenStack This release is part of the pike stable release series. The source is available from: https://git.openstack.org/cgit/openstack/zun Download the package from: https://tarballs.openstack.org/zun/ Please report issues through launchpad: https://bugs.launchpad.net/zun For more details, please see below. Changes in zun 0.1.0..0.2.0 --------------------------- 51f54b8 Add new entrypoint 'experimental' for capsules 5db8647 port pci whitelist from nova to zun 70020a9 Add capsule controller in API side and add create method 127794e port pci devspec from nova to zun 47f4b30 port pci utils from nova to zun d080604 Fix parameter name error in HostController 0095b46 Removing LOG in hosts.py 9b65448 Move all neutron calls to NeutronAPI ac7e288 Updated from global requirements 95a7b80 Fix the 'addresses' field of container 9a953d3 Allow glance image name/id support f8a9e45 Using utils.get_resource for getting host cd9d2db Implement create with specified neutron net 390e405 Dump docker daemon logs before finish eb21cd2 Needn't compute freecpu when unsetting container.cpu 88b8dbc Fix exception with wrong field. 7aba2d5 Switch from mode_wsgi to uwsgi 648a9cd Implement create with existing neutron port 019055e Move get_available_network to API layer 472aa90 Updated from global requirements 8b62dee Improve the validation of environment field 0144447 Allow add security group by uuid a204254 Fix the broken add_security_group endpoint e7faccf Add missing 'command' attribute c41b899 Imply compute node related Etcd API ffb5762 Get python3 tempest tests job to pass 548325b Py3: Finish the python3 port 7055afa Change tag link in README to the newest address 38085dc Update the documention for doc migration 57b25cb Fixed description in README.rst 2d7be38 Add filter scheduler doc. b001296 Image pull policy support for zun pull f62a8ae Add missing module import e14fbe5 Make some config options work 0bf9481 Remove unused requirement: greenlet 557b5b5 Add missing configuration index 5caaa8f Add delete_container to periodic task b793a1a Updated from global requirements 7d3f1a0 Check if security groups is duplicated or not in API 61b4b53 Add the capsule DB method 0b4c53e Add the Object Capsule and database table d7d1b68 Refactor Glance Image driver ad6cf73 container SR-IOV networking support 1304e0a Add host show api ba12241 [doc-migration] Add install and configuration folders 2b557f9 Stop using deprecated 'message' attribute in Exception 00f1581 Bump the version to 1.4 for host list api control 1b5bb28 Add host list api fa87508 Updated from global requirements a001c5a Make sandbox container optional 15cbc66 Update quickstart link in document 1d4899c Add admin folder for related documents 2a0a799 Added support for Auto remove the container 154bcf7 Updated from global requirements 563da72 Support show/delete with all_tenants 2c115f0 Add unit test for kuryr network driver e9afac0 Fix error in containers.inc 7605745 Fix docs & specs erros. 4b489da Add warning-is-error in setup.cfg 6e48d31 Move the contributor related docs to contributor/ dir 6d80dd6 Modify the Cinder integration spec bcca3b9 Add api-ref for container stats c45752a Refactor networking code of docker driver ef45c43 Refactor create/delete sandbox code d1d77e3 Minor refactor of get_security_group_ids 6a95beb Optimize connect_container_to_network ff01094 Updated from global requirements bb278a4 Update URLs in documents according to document migration d12e05c Correct devstack docs urls 4fcb465 Fix some errors and warnings 5659210 Refactor code 2b243b9 Fix rst markups in specs/cinder-integration.rst fd59140 Introduce policy rule for all tenants 7816f21 Add api-ref for more container operations 8f2ff32 Fix another upgrade from docker-py to docker place 8ce08d7 Fix hard code kuryr driver name bug c45bffe Revise the policy data 98654e6 Devstack stop zun-wsproxy process when service enabled 4788170 Optimize error in docker driver fb060cd Fix error in the log of container kill 769de27 Remove the NoopFilter f194efc Add missing REST API version history 9755062 Update the fake policy file 5904cc2 Enable H904 check 545b145 Refine default policy ff3f6e1 Replace unicode with six.text_type c2ea432 Rename kw to kwargs 1b00d55 Replace map with list 09edc12 Use __future__ module absolute_import f869fd1 Handle docker error consistently cba861f Updated from global requirements 718d5d0 Fix the sample responses in API docs e44e26f Add user specify network to create container fc0cf75 Add tempest tests for security groups 3a46560 Clean up network resources after tempest tests 9878441 Support python 3.5 ae8f9ca Optimize add_security_groups_to_container 9ae81a2 Optimize disconnection of container from network 81c225f Retrieve addresses when connecting to network cbcad3b Add api-ref for container operations d064258 Refactor code 5800952 Fixed an issue that container's host is None 5464b39 Correct the API microversion docs b969bef Fixed an wrong method call on kuryr driver 1d3d041 Delete log translation functions and add hacking rule 745cebc Remove unnecessary inspect in kill and related testcases f279bb9 Warning on running tempest tests 9bb3f6e Optimize helpinfo in zun/conf 4a0091c cors: update default configuration 8992bbb Fix openstackdocstheme settings a5a82b0 Change tag from unicode to str in docker commit 406b953 Revert the file mode from 0755 to 0644 32798ef PCI passthrough device modeling 18e7d3d Fix some comments about docker driver ec5a9c9 Switch from oslosphinx to openstackdocstheme ecd811b Remove log translations. 83c676f Set sandbox id immediately after sandbox create 5b8afdc Remove market function _() 391252d Updated from global requirements 8c7487a Drop duplicated exception handle code from docker commit d31ea90 Optimize _get_security_group_id f3a5e92 Optimize msg when exception 7fcac9c Add websockify to requirements 83f3c67 Remove the items for disable neutron 5ad57fe Rename variable, more meaningful naming. 8a94592 Remove unused code at zun.common.rpc bc480de Pass environment variables of proxy to tox d69c686 Fix label filter bug. 9180a8c Upgrade from docker-py to docker 9a1220c Updated from global requirements 435d3f8 Add claim limit in ram filter and cpu filter 8c7a97d Do not set container host before resource claimed eb91f4c Run tempest tests in parallel 22b47f5 Updated from global requirements 921dca4 Set access_policy for messaging's dispatcher 4c52457 Add api-ref for container create 893cd7c Add label filter dbeb80e Add return the image ID in container commit bc8375b Unset container's host if it failed to create 87687d2 Updated from global requirements c6861fa Fix html_last_updated_fmt for Python3. 340894a Remove duplicated hacking rule Z318 ff17dac Optimize the link address 0322c11 Remove deprecated oslo_messaging.transport.get_transport 6b1a4a1 Introduce container composition 891bbf8 Remove usage of parameter enforce_type f5488e6 Enable some off-by-default checks 9c63d9e Fix typo error in zun/hacking/checks.py 8fc5864 Log the network configuration c6f9aee Updated from global requirements 478e72d Add scheduler hint 99338b1 Remove resource claim when delete container 3f281ed Updated from global requirements 5ef6454 Change default scheduler to filter_scheduler a19de0d Using assertIsNone instead of assertEqual d377df2 Avoid creating port without security groups b8e77af Switch to 'eventlet' executor for rpc 46d007e Replace assertRaisesRegexp with assertRaisesRegex cad9fa3 Remove usage of parameter enforce_type e60649e Change the tempest test interval to 2s. 16f83bd Add the description about service api to api-ref ea0ba92 Revert "Temporarily disable etcd3 to fix the gate" 7c685ae Add devstack-plugin-container to vagrant 8d4325f Replace oslo_utils.timeutils.isotime 283fd8f Add tempest test for container commit d2edc7f Add more tempest tests for container run 7b3d2e7 Updated from global requirements 98dfe6c Updated from global requirements 2b3331a Raise ImageNotFound when image not found in docker c4c4f12 Updated from global requirements d1b1526 Add tempest tests for 'stats' endpoint 6f6c810 Temporarily disable etcd3 to fix the gate 73ead98 Switch to devstack-plugin-container c747023 Fix unicode error for python3 d119695 Optimize the link address 029b9e3 Add ram filter 677ba36 Change to git.openstack.org a514df5 Tests: make test_pull_image_exception reasonable 67eedb8 Add resource claim for zun. 9edb45d Updated from global requirements 1acfee4 Compile stats on server side 5161270 Tests: remove .testrepository/times.dbm in tox.ini f63a250 Support service force down 83d525c Add tempest tests for 'top' on container 7a25c24 Replace assertRaisesRegexp with assertRaisesRegex 7884d69 Add security-groups to container 2bd5d41 Add tempest test for container rename 8eb63ca Make docker api_url remotely accessible 89b8ea0 Support service-enable/disable a20071a Implement container snapshot bdaf779 Set docker_remote_api_ip in devstack 77cf455 Change the uuid from websocket header to querystring 8a1c854 Add multi host part for devstack guide 00adc1c Remove unused LOG in websocket a936744 Add 'host' to container db filters 72a7997 Add support for websocket-proxy 3e0cce8 MultiHost support 9f06090 Fix the zun.conf file for MultiHost env f50bf6f Put team mascot at the readme home page 2bb9862 Updated from global requirements 45ab53f Image: Catch glance image not found exception 13f1258 Updated from global requirements e55b40c Zun execute without command returned 500 c5e836f Remove nova docker instruction from quickstart 24c37bc Add a new service wsproxy to Zun 6f12f45 Handle the case when get_by_host_and_binary return None 294a5f1 Add two fields to container object 65d854d Server support for display snapshot of zun stats b3b145a Updated from global requirements 7940202 Add api_microversion_history to index f26f5c7 Correct how to run tempest test in README.rst cc9e19d oslo_service.periodic_task KeyError: 'NanoCpus' 416e112 Optimize the link address a2f335b Remove unused conf in kuryr_network.py 7d707d1 Rename higgins to zun aa6917a Handle the case that container.host is None e4561a5 Remove unused parameter in docker_load 75ce367 Use docker.logs instead of get_container_logs d79ec4e Fix the container.cpu is None in cpu_filter 3286c46 Add labels info to compute node b55985c Add CPUFilter for filter scheduler 3b16b11 Revert file mode from 0755 to 0644 9d16eb7 Add tests for api microversion 2ab2ced Add the docs for API Microversion a1adf43 Be robust on missing 'MaximumRetryCount' key 4c1e1e8 Introduce cpu-policy for container deployment Diffstat (except docs and test files) ------------------------------------- HACKING.rst | 5 +- README.rst | 20 +- api-ref/source/conf.py | 3 +- api-ref/source/containers.inc | 615 ++++++++++++++++++++ api-ref/source/hosts.inc | 86 +++ api-ref/source/index.rst | 1 + api-ref/source/parameters.yaml | 197 ++++++- api-ref/source/samples/container-create-req.json | 30 + api-ref/source/samples/container-create-resp.json | 37 ++ api-ref/source/samples/container-get-all-resp.json | 52 ++ api-ref/source/samples/container-rename-resp.json | 47 ++ api-ref/source/samples/container-show-resp.json | 47 ++ api-ref/source/samples/container-stats-resp.json | 9 + api-ref/source/samples/container-update-req.json | 4 + api-ref/source/samples/container-update-resp.json | 47 ++ api-ref/source/samples/host-get-all-resp.json | 23 + api-ref/source/samples/host-get-resp.json | 19 + api-ref/source/samples/service-disable-resp.json | 8 + api-ref/source/samples/service-enable-resp.json | 8 + api-ref/source/samples/service-forcedown-resp.json | 7 + api-ref/source/services.inc | 164 ++++++ contrib/vagrant/config/localrc | 5 +- contrib/vagrant/install_devstack.sh | 2 +- devstack/README.rst | 2 +- devstack/lib/zun | 171 ++---- devstack/local.conf.sample | 3 +- devstack/plugin.sh | 1 - devstack/settings | 9 +- etc/zun/policy.json | 57 +- etc/zun/policy.yaml.sample | 0 nova/virt/zun/client.py | 7 +- nova/virt/zun/driver.py | 35 +- nova/virt/zun/network.py | 2 +- nova/virt/zun/opencontrail.py | 4 +- nova/virt/zun/vifs.py | 4 +- releasenotes/source/conf.py | 19 +- requirements.txt | 32 +- setup.cfg | 4 + specs/cinder-integration.rst | 246 +++++--- specs/container-SRIOV-networking.rst | 228 ++++++++ specs/container-composition.rst | 401 +++++++++++++ specs/container-interactive-mode.rst | 4 +- specs/container-sandbox.rst | 2 +- specs/container-snapshot.rst | 58 +- specs/cpuset-container.rst | 179 ++++++ specs/kuryr-integration.rst | 65 ++- specs/pci-device-model.rst | 230 ++++++++ specs/zun-api-validation.rst | 8 +- template/capsule/capsule.yaml | 62 ++ test-requirements.txt | 10 +- tox.ini | 4 + zun/__init__.py | 1 + zun/api/app.wsgi | 24 +- zun/api/controllers/base.py | 3 +- zun/api/controllers/experimental/__init__.py | 152 +++++ zun/api/controllers/experimental/capsules.py | 244 ++++++++ zun/api/controllers/experimental/collection.py | 43 ++ .../controllers/experimental/schemas/__init__.py | 0 .../controllers/experimental/schemas/capsules.py | 26 + zun/api/controllers/experimental/views/__init__.py | 0 .../experimental/views/capsules_view.py | 49 ++ zun/api/controllers/root.py | 4 +- zun/api/controllers/types.py | 2 +- zun/api/controllers/v1/__init__.py | 15 +- zun/api/controllers/v1/containers.py | 300 +++++++--- zun/api/controllers/v1/hosts.py | 109 ++++ zun/api/controllers/v1/images.py | 9 +- zun/api/controllers/v1/schemas/containers.py | 46 +- zun/api/controllers/v1/schemas/images.py | 3 +- zun/api/controllers/v1/schemas/services.py | 50 ++ zun/api/controllers/v1/views/containers_view.py | 4 +- zun/api/controllers/v1/views/hosts_view.py | 49 ++ zun/api/controllers/v1/views/images_view.py | 3 +- zun/api/controllers/v1/zun_services.py | 106 +++- zun/api/controllers/versions.py | 14 +- zun/api/http_error.py | 11 +- zun/api/middleware/auth_token.py | 6 +- zun/api/middleware/parsable_error.py | 2 +- zun/api/rest_api_version_history.rst | 52 ++ zun/api/versioned_method.py | 70 +-- zun/api/wsgi.py | 35 ++ zun/cmd/wsproxy.py | 39 ++ zun/common/config.py | 40 +- zun/common/consts.py | 2 + zun/common/exception.py | 111 +++- zun/common/i18n.py | 3 +- zun/common/name_generator.py | 4 +- zun/common/paths.py | 6 +- zun/common/policy.py | 2 +- zun/common/profiler.py | 3 +- zun/common/rpc.py | 67 +-- zun/common/rpc_service.py | 24 +- zun/common/short_id.py | 2 +- zun/common/utils.py | 77 ++- zun/common/validation/parameter_types.py | 47 +- zun/common/validation/validators.py | 5 +- zun/compute/api.py | 68 ++- zun/compute/claims.py | 171 ++++++ zun/compute/compute_node_tracker.py | 204 ++++++- zun/compute/manager.py | 420 ++++++++++---- zun/compute/rpcapi.py | 39 +- zun/conf/__init__.py | 2 + zun/conf/api.py | 17 +- zun/conf/container_driver.py | 10 + zun/conf/database.py | 18 +- zun/conf/docker.py | 5 +- zun/conf/glance_client.py | 25 +- zun/conf/image_driver.py | 5 +- zun/conf/network.py | 4 + zun/conf/neutron_client.py | 19 +- zun/conf/nova_client.py | 16 +- zun/conf/scheduler.py | 5 +- zun/conf/services.py | 13 +- zun/conf/websocket_proxy.py | 92 +++ zun/conf/zun_client.py | 22 +- zun/container/docker/driver.py | 487 ++++++++++------ zun/container/docker/host.py | 42 ++ zun/container/docker/utils.py | 24 +- zun/container/driver.py | 88 +-- zun/container/os_capability/host_capability.py | 3 +- zun/db/api.py | 77 +++ zun/db/etcd/api.py | 120 +++- zun/db/etcd/models.py | 72 ++- .../versions/174cafda0857_add_security_groups.py | 39 ++ .../17ab8b533cc8_add_container_hosts_label_info.py | 37 ++ ...3b2322_add_websocket_url_and_websocket_token.py | 37 ++ .../648c25faa0be_add_mem_used_to_compute_node.py | 33 ++ .../75315e219cfb_add_auto_remove_to_container.py | 34 ++ .../versions/a251f1f61217_create_capsule_table.py | 58 ++ .../a9a92eebd9a8_create_table_higgins_service.py | 48 -- .../a9a92eebd9a8_create_table_zun_service.py | 48 ++ zun/db/sqlalchemy/api.py | 75 ++- zun/db/sqlalchemy/models.py | 38 +- zun/hacking/checks.py | 43 +- zun/image/docker/driver.py | 34 +- zun/image/driver.py | 52 +- zun/image/glance/driver.py | 54 +- zun/image/glance/utils.py | 44 +- zun/network/kuryr_network.py | 151 +++-- zun/network/network.py | 6 +- zun/network/neutron.py | 92 +++ zun/objects/__init__.py | 3 + zun/objects/base.py | 77 +++ zun/objects/capsule.py | 152 +++++ zun/objects/compute_node.py | 6 +- zun/objects/container.py | 23 +- zun/objects/fields.py | 4 +- zun/objects/zun_service.py | 22 +- zun/pci/__init__.py | 0 zun/pci/devspec.py | 289 ++++++++++ zun/pci/utils.py | 183 ++++++ zun/pci/whitelist.py | 94 ++++ zun/scheduler/base_filters.py | 11 +- zun/scheduler/chance_scheduler.py | 2 +- zun/scheduler/client.py | 8 +- zun/scheduler/driver.py | 4 +- zun/scheduler/filter_scheduler.py | 210 +++---- zun/scheduler/filters/__init__.py | 90 +-- zun/scheduler/filters/cpu_filter.py | 42 ++ zun/scheduler/filters/label_filter.py | 50 ++ zun/scheduler/filters/noop_filter.py | 34 -- zun/scheduler/filters/ram_filter.py | 43 ++ zun/scheduler/host_state.py | 33 ++ zun/service/periodic.py | 3 +- zun/servicegroup/zun_service_periodic.py | 4 +- .../unit/api/controllers/v1/test_containers.py | 625 +++++++++++++++++---- .../unit/api/controllers/v1/test_zun_service.py | 50 ++ .../unit/container/docker/test_docker_driver.py | 248 ++++---- .../test_os_capability_linux.py | 3 +- .../unit/scheduler/filters/test_cpu_filter.py | 45 ++ .../unit/scheduler/filters/test_label_filter.py | 42 ++ .../unit/scheduler/filters/test_ram_filter.py | 45 ++ zun/version.py | 5 +- zun/websocket/__init__.py | 0 zun/websocket/websocketclient.py | 40 ++ zun/websocket/websocketproxy.py | 267 +++++++++ 254 files changed, 13172 insertions(+), 3014 deletions(-) Requirements updates -------------------- diff --git a/requirements.txt b/requirements.txt index 99ae6be..0f08500 100644 --- a/requirements.txt +++ b/requirements.txt @@ -6 +6 @@ PyYAML>=3.10.0 # MIT -eventlet!=0.18.3,>=0.18.2 # MIT +eventlet!=0.18.3,!=0.20.1,<0.21.0,>=0.18.2 # MIT @@ -8 +7,0 @@ keystonemiddleware>=4.12.0 # Apache-2.0 -greenlet>=0.3.2 # MIT @@ -13,4 +12,4 @@ python-etcd>=0.4.3 # MIT License -python-glanceclient>=2.5.0 # Apache-2.0 -python-neutronclient>=5.1.0 # Apache-2.0 -python-novaclient>=7.1.0 # Apache-2.0 -oslo.i18n>=2.1.0 # Apache-2.0 +python-glanceclient>=2.8.0 # Apache-2.0 +python-neutronclient>=6.3.0 # Apache-2.0 +python-novaclient>=9.0.0 # Apache-2.0 +oslo.i18n!=3.15.2,>=2.1.0 # Apache-2.0 @@ -19,5 +18,5 @@ oslo.concurrency>=3.8.0 # Apache-2.0 -oslo.config>=3.22.0 # Apache-2.0 -oslo.messaging>=5.19.0 # Apache-2.0 -oslo.middleware>=3.10.0 # Apache-2.0 -oslo.policy>=1.17.0 # Apache-2.0 -oslo.serialization>=1.10.0 # Apache-2.0 +oslo.config!=4.3.0,!=4.4.0,>=4.0.0 # Apache-2.0 +oslo.messaging!=5.25.0,>=5.24.2 # Apache-2.0 +oslo.middleware>=3.27.0 # Apache-2.0 +oslo.policy>=1.23.0 # Apache-2.0 +oslo.serialization!=2.19.1,>=1.10.0 # Apache-2.0 @@ -26 +25 @@ oslo.versionedobjects>=1.17.0 # Apache-2.0 -oslo.context>=2.12.0 # Apache-2.0 +oslo.context>=2.14.0 # Apache-2.0 @@ -28,2 +27,2 @@ oslo.utils>=3.20.0 # Apache-2.0 -oslo.db>=4.19.0 # Apache-2.0 -os-vif>=1.4.0 # Apache-2.0 +oslo.db>=4.24.0 # Apache-2.0 +os-vif>=1.7.0 # Apache-2.0 @@ -34 +33,4 @@ stevedore>=1.20.0 # Apache-2.0 -docker-py>=1.8.1 # Apache-2.0 +docker>=2.0.0 # Apache-2.0 +netaddr!=0.7.16,>=0.7.13 # BSD +neutron-lib>=1.9.0 # Apache-2.0 +websockify>=0.8.0 # LGPLv3 diff --git a/test-requirements.txt b/test-requirements.txt index 1090876..3cc34ec 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -8 +8 @@ doc8 # Apache-2.0 -coverage>=4.0 # Apache-2.0 +coverage!=4.4,>=4.0 # Apache-2.0 @@ -13,2 +13,2 @@ python-subunit>=0.0.18 # Apache-2.0/BSD -sphinx>=1.5.1 # BSD -oslosphinx>=4.7.0 # Apache-2.0 +sphinx>=1.6.2 # BSD +openstackdocstheme>=1.16.0 # Apache-2.0 @@ -19 +19 @@ PyMySQL>=0.7.6 # MIT License -tempest>=14.0.0 # Apache-2.0 +tempest>=16.1.0 # Apache-2.0 @@ -24 +24 @@ testtools>=1.4.0 # MIT -reno>=1.8.0 # Apache-2.0 +reno!=2.3.1,>=1.8.0 # Apache-2.0