openstack-manuals/doc/install-guide/section_keystone-openrc.xml
Tom Fifield 046498d7be Add a note to educate on keystone's two ports
As suggested by Dung K Hoang, readers find the use of two different
ports in keystone confusing. This patch adds a short explanatory note

Change-Id: I17bccf993f6dc12c1e2a1f9099fbddf53dd1b202
Closes-Bug: 1384970
2014-11-19 22:20:35 +08:00

57 lines
2.9 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<section xmlns="http://docbook.org/ns/docbook"
xmlns:xi="http://www.w3.org/2001/XInclude"
xmlns:xlink="http://www.w3.org/1999/xlink"
version="5.0"
xml:id="keystone-client-environment-scripts">
<title>Create OpenStack client environment scripts</title>
<para>The previous section used a combination of environment variables and
command options to interact with the Identity service via the
<command>keystone</command> client. To increase efficiency of client
operations, OpenStack supports simple client environment scripts also
known as OpenRC files. These scripts typically contain common options for
all clients, but also support unique options. For more information, see the
<link xlink:href="http://docs.openstack.org/user-guide/content/cli_openrc.html">OpenStack User Guide</link>.</para>
<procedure>
<title>To create the scripts</title>
<para>Create client environment scripts for the <literal>admin</literal>
and <literal>demo</literal> tenants and users. Future portions of this
guide reference these scripts to load appropriate credentials for client
operations.</para>
<step>
<para>Edit the <filename>admin-openrc.sh</filename> file and add the
following content:</para>
<programlisting language="bash">export OS_TENANT_NAME=admin
export OS_USERNAME=admin
export OS_PASSWORD=<replaceable>ADMIN_PASS</replaceable>
export OS_AUTH_URL=http://<replaceable>controller</replaceable>:35357/v2.0</programlisting>
<para>Replace <literal>ADMIN_PASS</literal> with the password you chose
for the <literal>admin</literal> user in the Identity service.</para>
</step>
<step>
<para>Edit the <filename>demo-openrc.sh</filename> file and add the
following content:</para>
<programlisting language="bash">export OS_TENANT_NAME=demo
export OS_USERNAME=demo
export OS_PASSWORD=<replaceable>DEMO_PASS</replaceable>
export OS_AUTH_URL=http://<replaceable>controller</replaceable>:5000/v2.0</programlisting>
<para>Replace <literal>DEMO_PASS</literal> with the password you chose
for the <literal>demo</literal> user in the Identity service.</para>
</step>
</procedure>
<note><title>Identity ports</title>
<para>Note the two different ports used above. Port 35357 is used for
administrative functions only. Port 5000 is for normal user
functions and is the most commonly used.</para></note>
<procedure>
<title>To load client environment scripts</title>
<step>
<para>To run clients as a certain tenant and user, you can simply load
the associated client environment script prior to running them. For
example, to load the location of the Identity service and
<literal>admin</literal> tenant and user credentials:</para>
<screen><prompt>$</prompt> <userinput>source admin-openrc.sh</userinput></screen>
</step>
</procedure>
</section>