Update README with CLI commands

Closes-Bug: #1433745
Change-Id: Ia2774648da866d1c98b42feb70dd8881509264dc
This commit is contained in:
Amey Bhide 2015-03-23 13:59:08 -07:00
parent 46e276766d
commit ee3dcb60c3
2 changed files with 8 additions and 13 deletions

View File

@ -25,14 +25,14 @@ To execute CLI commands to standalone congress set with noauth:
$ python setup.py install $ python setup.py install
* Edit congress_noauth and fix CONGRESS_URL to point to correct congress server * To execute CLI commands::
* Run script "congress_noauth" to execute CLI commands::
$ cd python-congressclient $ cd python-congressclient
For example: For example:
$ ./congress_noauth policy create test_policy $ export CONGRESS_URL="http://127.0.0.1:1789"
$ openstack --os-token foo --os-url $CONGRESS_URL
(openstack) congress policy create test_policy
+--------------+--------------------------------------+ +--------------+--------------------------------------+
| Field | Value | | Field | Value |
+--------------+--------------------------------------+ +--------------+--------------------------------------+
@ -44,7 +44,7 @@ To execute CLI commands to standalone congress set with noauth:
| owner_id | user | | owner_id | user |
+--------------+--------------------------------------+ +--------------+--------------------------------------+
$ ./congress_noauth policy rule create test_policy "p(5)" (openstack) congress policy rule create test_policy "p(5)"
+---------+--------------------------------------+ +---------+--------------------------------------+
| Field | Value | | Field | Value |
+---------+--------------------------------------+ +---------+--------------------------------------+
@ -54,11 +54,13 @@ To execute CLI commands to standalone congress set with noauth:
| rule | p(5) | | rule | p(5) |
+---------+--------------------------------------+ +---------+--------------------------------------+
$ ./congress_noauth policy rule list test_policy (openstack) congress policy rule list test_policy
// ID: 5ce7fb18-a227-447e-bec8-93e99c0052a5 // ID: 5ce7fb18-a227-447e-bec8-93e99c0052a5
// Name: None // Name: None
p(5) p(5)
(openstack) exit
$
Features Features
-------- --------

View File

@ -1,7 +0,0 @@
#!/bin/bash
CONGRESS_URL="http://127.0.0.1:1789"
COMMAND_PREFIX="openstack --os-token foo --os-url $CONGRESS_URL congress"
CMD="$COMMAND_PREFIX $@"
exec $CMD