changed docs about using project id
This commit is contained in:
parent
882a266387
commit
ff7e725f92
@ -36,11 +36,12 @@ Installing this package gets you a shell command, ``nova``, that you
|
||||
can use to interact with any Rackspace compatible API (including OpenStack).
|
||||
|
||||
You'll need to provide your OpenStack username and API key. You can do this
|
||||
with the ``--username`` and ``--apikey`` params, but it's easier to just
|
||||
with the ``--username``, ``--apikey`` and ``--projectid`` params, but it's easier to just
|
||||
set them as environment variables::
|
||||
|
||||
export NOVA_USERNAME=openstack
|
||||
export NOVA_API_KEY=yadayada
|
||||
export NOVA_PROJECT_ID=myproject
|
||||
|
||||
You will also need to define the authentication url with ``--url``. Or set it as
|
||||
an environment variable as well::
|
||||
@ -51,7 +52,7 @@ You'll find complete documentation on the shell by running
|
||||
``nova help``::
|
||||
|
||||
usage: nova [--username USERNAME] [--apikey APIKEY]
|
||||
[--url AUTH_URL] <subcommand> ...
|
||||
[--projectid PROJECTID] [--url AUTH_URL] <subcommand> ...
|
||||
|
||||
Command-line interface to the OpenStack Nova API.
|
||||
|
||||
@ -93,6 +94,7 @@ You'll find complete documentation on the shell by running
|
||||
Optional arguments:
|
||||
--username USERNAME Defaults to env[NOVA_USERNAME].
|
||||
--apikey APIKEY Defaults to env[NOVA_API_KEY].
|
||||
--apikey PROJECTID Defaults to env[NOVA_PROJECT_ID].
|
||||
--url AUTH_URL Defaults to env[NOVA_URL] or
|
||||
https://auth.api.rackspacecloud.com/v1.0
|
||||
if undefined.
|
||||
@ -109,7 +111,7 @@ __ http://packages.python.org/python-novaclient/
|
||||
By way of a quick-start::
|
||||
|
||||
>>> import novaclient
|
||||
>>> nt = novaclient.OpenStack(USERNAME, API_KEY [, AUTH_URL])
|
||||
>>> nt = novaclient.OpenStack(USERNAME, API_KEY,PROJECT_ID [, AUTH_URL])
|
||||
>>> nt.flavors.list()
|
||||
[...]
|
||||
>>> nt.servers.list()
|
||||
|
@ -11,9 +11,9 @@ First, you'll need an OpenStack Nova account and an API key. You get this
|
||||
by using the `nova-manage` command in OpenStack Nova.
|
||||
|
||||
You'll need to provide :program:`nova` with your OpenStack username and
|
||||
API key. You can do this with the :option:`--username` and :option:`--apikey`
|
||||
options, but it's easier to just set them as environment variables by setting
|
||||
two environment variables:
|
||||
API key. You can do this with the :option:`--username`, :option:`--apikey`
|
||||
and :option:`--projectid` options, but it's easier to just set them as
|
||||
environment variables by setting two environment variables:
|
||||
|
||||
.. envvar:: NOVA_USERNAME
|
||||
|
||||
@ -23,6 +23,10 @@ two environment variables:
|
||||
|
||||
Your API key.
|
||||
|
||||
.. envvar:: NOVA_PROJECT_ID
|
||||
|
||||
Project for work.
|
||||
|
||||
.. envvar:: NOVA_URL
|
||||
|
||||
The OpenStack API server URL.
|
||||
@ -31,6 +35,7 @@ For example, in Bash you'd use::
|
||||
|
||||
export NOVA_USERNAME=yourname
|
||||
export NOVA_API_KEY=yadayadayada
|
||||
export NOVA_PROJECT_ID=myproject
|
||||
export NOVA_URL=http://...
|
||||
|
||||
From there, all shell commands take the form::
|
||||
|
Loading…
x
Reference in New Issue
Block a user