简体   繁体   中英

Configure the administrative account

I'm deploying openstack- stein version on ubuntu pro 18.04 LTS.

I come across these lines when configuring keystone - identity service, as of this article .

Would anybody please explain how to set this following configuration:

$ export OS_USERNAME=admin
$ export OS_PASSWORD=ADMIN_PASS
$ export OS_PROJECT_NAME=admin
$ export OS_USER_DOMAIN_NAME=Default
$ export OS_PROJECT_DOMAIN_NAME=Default
$ export OS_AUTH_URL=http://controller:5000/v3
$ export OS_IDENTITY_API_VERSION=3

If I'm already in root mode, is there any need to these env variables?


If the question helped, up-vote it.

Whether you are root or not has no meaning for the openstack command. The OpenStack admin user has nothing to do with the Linux root user.

You don't need the variables, but your command line becomes very long without them, for example openstack --os-username=admin --os-password=ADMIN_PASS --os-project-name=admin --os-user-domain-name=Default --os-project-domain-name=Default --os-auth-url=http://controller:5000/v3 --os-identity-api-version=3 server list . These variables are the most convenient way to tell the openstack command under which identity it should perform its actions.

How to set them? Type them on the command line, but the most common method is putting them in a file that you source . You can then have several such files for several different identities, such as the admin and demo identities in the linked document, which allows you to quickly switch from one identity to the other.

In short, put those commands in admin-openrc.sh , then source admin-openrc.sh when you need to use openstack-cli with administrative account.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM