Explicitly unset OS_CLOUD in the generated openrc
If running in an environment with OS_CLOUD already set, it takes priority over what we source from openrc. Unset it. Also always set OS_AUTH_TYPE for upgrade situations. Change-Id: I7cc14426c76aafdc1aa1c076b25d8cb4b262e855
This commit is contained in:
parent
9d905e6b2b
commit
79d3af7636
@ -1,7 +1,13 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# WARNING: This file is managed by bifrost.
|
||||
for _os_key in $(set | awk '{FS="="} /^OS_/ {print $1}'); do
|
||||
unset $_os_key;
|
||||
done
|
||||
unset _os_key
|
||||
|
||||
{% if enable_keystone | bool %}
|
||||
export OS_AUTH_TYPE=password
|
||||
case "$1" in
|
||||
{% for cloud in clouds | default({}) | dictsort %}
|
||||
# Section for {{ cloud.0 }}
|
||||
@ -23,7 +29,6 @@ export OS_ENDPOINT={{ ironic_api_url }}
|
||||
{% else %}
|
||||
export OS_AUTH_TYPE=http_basic
|
||||
export OS_ENDPOINT={{ ironic_api_url }}
|
||||
unset OS_AUTH_URL
|
||||
case "${1:-bifrost}" in
|
||||
"bifrost")
|
||||
export OS_USERNAME="{{ default_username }}"
|
||||
|
@ -0,0 +1,6 @@
|
||||
---
|
||||
fixes:
|
||||
- |
|
||||
Unsets the ``OS_CLOUD`` variable in the generated ``openrc``.
|
||||
- |
|
||||
``OS_AUTH_TYPE`` is now always set in the generated ``openrc``.
|
Loading…
x
Reference in New Issue
Block a user