Enable the nova microversion api

* Use the nova microversion api for compute service
* Use the legacy nova api for compute_legacy service
* Update the nova service and endpoint during the upgrade stage

This is what the devstack used now[0]

[0]
e777bbce3b/lib/nova (L408),L422

TrivialFix

Change-Id: I0574a3116b1dd1702b4eccb2394538866675c4c1
This commit is contained in:
Jeffrey Zhang 2016-07-28 22:58:58 +08:00
parent cae30a913b
commit 1ce1cd10fe
4 changed files with 21 additions and 9 deletions

View File

@ -71,9 +71,13 @@ nova_compute_ironic_image_full: "{{ nova_compute_ironic_image }}:{{ nova_compute
#################### ####################
# OpenStack # OpenStack
#################### ####################
nova_admin_endpoint: "{{ admin_protocol }}://{{ kolla_internal_fqdn }}:{{ nova_api_port }}/v2/%(tenant_id)s" nova_legacy_admin_endpoint: "{{ admin_protocol }}://{{ kolla_internal_fqdn }}:{{ nova_api_port }}/v2/%(tenant_id)s"
nova_internal_endpoint: "{{ internal_protocol }}://{{ kolla_internal_fqdn }}:{{ nova_api_port }}/v2/%(tenant_id)s" nova_legacy_internal_endpoint: "{{ internal_protocol }}://{{ kolla_internal_fqdn }}:{{ nova_api_port }}/v2/%(tenant_id)s"
nova_public_endpoint: "{{ public_protocol }}://{{ kolla_external_fqdn }}:{{ nova_api_port }}/v2/%(tenant_id)s" nova_legacy_public_endpoint: "{{ public_protocol }}://{{ kolla_external_fqdn }}:{{ nova_api_port }}/v2/%(tenant_id)s"
nova_admin_endpoint: "{{ admin_protocol }}://{{ kolla_internal_fqdn }}:{{ nova_api_port }}/v2.1/%(tenant_id)s"
nova_internal_endpoint: "{{ internal_protocol }}://{{ kolla_internal_fqdn }}:{{ nova_api_port }}/v2.1/%(tenant_id)s"
nova_public_endpoint: "{{ public_protocol }}://{{ kolla_external_fqdn }}:{{ nova_api_port }}/v2.1/%(tenant_id)s"
nova_logging_debug: "{{ openstack_logging_debug }}" nova_logging_debug: "{{ openstack_logging_debug }}"

View File

@ -2,9 +2,9 @@
- name: Creating the Nova service and endpoint - name: Creating the Nova service and endpoint
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost command: docker exec -t kolla_toolbox /usr/bin/ansible localhost
-m kolla_keystone_service -m kolla_keystone_service
-a "service_name=nova -a "service_name={{ item.name }}
service_type=compute service_type={{ item.service_type }}
description='Openstack Compute' description='{{ item.description }}'
endpoint_region={{ openstack_region_name }} endpoint_region={{ openstack_region_name }}
url='{{ item.url }}' url='{{ item.url }}'
interface='{{ item.interface }}' interface='{{ item.interface }}'
@ -18,9 +18,12 @@
delay: 5 delay: 5
run_once: True run_once: True
with_items: with_items:
- {'interface': 'admin', 'url': '{{ nova_admin_endpoint }}'} - {'name': 'nova_legacy', 'service_type': 'compute_legacy', 'interface': 'admin', 'url': '{{ nova_legacy_admin_endpoint }}', 'description': 'OpenStack Compute Service (Legacy 2.0)'}
- {'interface': 'internal', 'url': '{{ nova_internal_endpoint }}'} - {'name': 'nova_legacy', 'service_type': 'compute_legacy', 'interface': 'internal', 'url': '{{ nova_legacy_internal_endpoint }}', 'description': 'OpenStack Compute Service (Legacy 2.0)'}
- {'interface': 'public', 'url': '{{ nova_public_endpoint }}'} - {'name': 'nova_legacy', 'service_type': 'compute_legacy', 'interface': 'public', 'url': '{{ nova_legacy_public_endpoint }}', 'description': 'OpenStack Compute Service (Legacy 2.0)'}
- {'name': 'nova', 'service_type': 'compute', 'interface': 'admin', 'url': '{{ nova_admin_endpoint }}', 'description': 'OpenStack Compute Service'}
- {'name': 'nova', 'service_type': 'compute', 'interface': 'internal', 'url': '{{ nova_internal_endpoint }}', 'description': 'OpenStack Compute Service'}
- {'name': 'nova', 'service_type': 'compute', 'interface': 'public', 'url': '{{ nova_public_endpoint }}', 'description': 'OpenStack Compute Service'}
- name: Creating the Nova project, user, and role - name: Creating the Nova project, user, and role
command: docker exec -t kolla_toolbox /usr/bin/ansible localhost command: docker exec -t kolla_toolbox /usr/bin/ansible localhost

View File

@ -8,6 +8,8 @@
- include: bootstrap_service.yml - include: bootstrap_service.yml
- include: register.yml
- name: Checking if conductor container needs upgrading - name: Checking if conductor container needs upgrading
kolla_docker: kolla_docker:
action: "compare_image" action: "compare_image"

View File

@ -0,0 +1,3 @@
---
features:
- Enable the nova microversion api