commit f22b46efbf91792df41db1764218a7ae89e85b43
Author: Jerry Sun <email address hidden>
Date: Thu Sep 15 14:22:56 2022 -0400
Set default project domain name to "Default"
Openrc files downloaded through Horizon does not set
OS_PROJECT_DOMAIN_NAME. This means openrc files downloaded from
horizon cannot be used to issue commands to sw-manager, even if
the user they refer to is supposed to be able to issue commands
to sw-manager. This is because nfv-client rejects commands if no
project domain name is specified.
This commit sets the nfv-client's project domain name to "Default"
when none is passed through command line parameters or environment
variables.
The "Default" domain is the default for openstack deployments and
starlingx. Assuming it as a default will not expose a security risk
as this information is not a secret. Users can override the default
value of "Default" by specifying the project domain name through
environment variables or the command line.
A change in nvf-client is done over a change in horizon in order to
minimize changes to components that starlingx does not own. Also,
none of starlingx's other components uses the project domain name.
Nfv client's authentication mechanism is not changed to use something
other than project domain name because that is a major change, and
could potentially cause compatibiltiy issues with
(orchestrated) upgrades.
Test Cases:
PASS: sw-manager upgrade-strategy-show with /etc/platform/openrc
PASS: sw-manager upgrade-strategy-show with admin openrc from horizon
ensure it is successful instead of failure due to lack of
project domain name
PASS: sw-manager upgrad-estrategy-show with admin openrc from horizon,
then manually specifying incorrect OS_PROJECT_DOMAIN_NAME through environment variable. Ensure this failed and that authentication
actually uses this field.
Change-Id: Ib2e22e9f5556b01115ab0adfb3c9a399825c49d5
Closes-bug: 1989796
Signed-off-by: Jerry Sun <email address hidden>
Reviewed: https:/ /review. opendev. org/c/starlingx /nfv/+/ 857945 /opendev. org/starlingx/ nfv/commit/ f22b46efbf91792 df41db1764218a7 ae89e85b43
Committed: https:/
Submitter: "Zuul (22348)"
Branch: master
commit f22b46efbf91792 df41db1764218a7 ae89e85b43
Author: Jerry Sun <email address hidden>
Date: Thu Sep 15 14:22:56 2022 -0400
Set default project domain name to "Default"
Openrc files downloaded through Horizon does not set PROJECT_ DOMAIN_ NAME. This means openrc files downloaded from
OS_
horizon cannot be used to issue commands to sw-manager, even if
the user they refer to is supposed to be able to issue commands
to sw-manager. This is because nfv-client rejects commands if no
project domain name is specified.
This commit sets the nfv-client's project domain name to "Default"
when none is passed through command line parameters or environment
variables.
The "Default" domain is the default for openstack deployments and
starlingx. Assuming it as a default will not expose a security risk
as this information is not a secret. Users can override the default
value of "Default" by specifying the project domain name through
environment variables or the command line.
A change in nvf-client is done over a change in horizon in order to
minimize changes to components that starlingx does not own. Also,
none of starlingx's other components uses the project domain name.
Nfv client's authentication mechanism is not changed to use something
other than project domain name because that is a major change, and
could potentially cause compatibiltiy issues with
(orchestrated) upgrades.
Test Cases:
PASS: sw-manager upgrade- strategy- show with /etc/platform/ openrc strategy- show with admin openrc from horizon estrategy- show with admin openrc from horizon, DOMAIN_ NAME through
environment variable. Ensure this failed and that authentication
PASS: sw-manager upgrade-
ensure it is successful instead of failure due to lack of
project domain name
PASS: sw-manager upgrad-
then manually specifying incorrect OS_PROJECT_
actually uses this field.
Change-Id: Ib2e22e9f5556b0 1115ab0adfb3c9a 399825c49d5
Closes-bug: 1989796
Signed-off-by: Jerry Sun <email address hidden>