Skip to content

Commit

Permalink
Merge "Always write clouds.yaml"
Browse files Browse the repository at this point in the history
  • Loading branch information
Jenkins authored and openstack-gerrit committed Mar 17, 2017
2 parents 19ef1f2 + de0a964 commit 36e32ec
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 3 deletions.
1 change: 0 additions & 1 deletion playbooks/install.yaml
Expand Up @@ -22,7 +22,6 @@
config_project_name: "{{ keystone.bootstrap.project_name }}"
config_region_name: "{{ keystone.bootstrap.region_name }}"
config_auth_url: "{{ keystone.bootstrap.public_url }}"
when: enable_keystone is defined and enable_keystone | bool == true
- { role: bifrost-create-dib-image, dib_imagename: "{{ http_boot_folder }}/ipa", build_ramdisk: false, dib_os_element: "{{ ipa_dib_os_element|default('debian') }}", dib_elements: "ironic-agent {{ ipa_extra_dib_elements | default('') }}", when: create_ipa_image | bool == true }
- { role: bifrost-create-dib-image, dib_imagename: "{{ deploy_image }}", dib_imagetype: "qcow2", dib_elements: "vm enable-serial-console {{ dib_init_element|default('simple-init') }} {{ extra_dib_elements|default('') }}", when: create_image_via_dib | bool == true and transform_boot_image | bool == false }
environment:
Expand Down
@@ -1,2 +1,2 @@
---
# This file is intentionally empty
ironic_api_url: "http://localhost:6385"
Expand Up @@ -23,6 +23,7 @@
config_project_domain_id: "{{ config_project_domain_id|default('default') }}"
config_user_domain_id: "{{ config_user_domain_id|default('default') }}"
when:
- "{{ enable_keystone | default(false) | bool }}"
- "{{ clouds is undefined }}"
- "{{ config_username is defined }}"
- "{{ config_password is defined }}"
Expand Down
@@ -1,5 +1,6 @@
# WARNING: This file is managed by bifrost.
clouds:
{% if (enable_keystone | default(false) | bool) %}
{% for cloud in clouds | default({}) | dictsort %}
{{ cloud.0 }}:
region_name: {{ cloud.1.config_region_name }}
Expand All @@ -12,3 +13,9 @@ clouds:
user_domain_id: "{{ cloud.1.config_user_domain_id | default('default') }}"
identity_api_version: "3"
{% endfor %}
{% else %}
bifrost:
auth_type: None
auth: {}
url: {{ ironic_api_url }}
{% endif %}
1 change: 0 additions & 1 deletion playbooks/test-bifrost.yaml
Expand Up @@ -87,7 +87,6 @@
config_project_name: "baremetal"
config_region_name: "{{ keystone.bootstrap.region_name }}"
config_auth_url: "{{ keystone.bootstrap.public_url }}"
when: "{{ enable_keystone is defined and enable_keystone | bool == true }}"
environment:
http_proxy: "{{ lookup('env','http_proxy') }}"
https_proxy: "{{ lookup('env','https_proxy') }}"
Expand Down
12 changes: 12 additions & 0 deletions releasenotes/notes/always-create-clouds-file-d0b72808155a9344.yaml
@@ -0,0 +1,12 @@
---
features:
- |
bifrost now always writes ``clouds.yaml`` configuration file
for os-client-config independently of whether keystone is installed
or not.
This allows unified usage of ironic-related openstackclient commands
both in presence and absence of installed keystone by using the
``openstack`` command in the following form for both situations::
openstack --os-cloud bifrost baremetal ...

0 comments on commit 36e32ec

Please sign in to comment.