跳转到主要内容

Congress客户端

项目描述

Congress客户端

独立Congress客户端

通过克隆仓库并运行设置文件来安装Congress CLI。主仓库始终包含最新的源代码,因此如果您正在安装和测试Congress的特定分支,请克隆python-congressclient的匹配分支。

执行无认证安装的独立Congress的CLI命令

  • 安装python-openstackclient

    $ pip install python-openstackclient
  • 克隆主仓库并安装python-congressclient

    $ git clone https://github.com/openstack/python-congressclient.git
    $ cd python-congressclient
    $ python setup.py install
  • (可选) 克隆分支;例如,如果你正在使用 OpenStack 和 Congress 的 Ocata 版本

    $ git clone -b stable/ocata https://github.com/openstack/python-congressclient.git
    $ cd python-congressclient
    $ python setup.py install
  • 阅读 HTML 文档。如果缺少,请安装 python-sphinx 和 oslosphinx 扩展

    $ sudo pip install sphinx
    $ sudo pip install oslosphinx

    构建文档 $ make docs

    在浏览器中打开 doc/html/index.html

  • 执行 CLI 命令

    $ cd python-congressclient
    
    For example:
    $ 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                                |
    +--------------+--------------------------------------+
    | abbreviation | test_                                |
    | description  |                                      |
    | id           | 8595f24a-7d74-45ee-8168-0b3e937b8419 |
    | kind         | nonrecursive                         |
    | name         | test_policy                          |
    | owner_id     | user                                 |
    +--------------+--------------------------------------+
    
    (openstack) congress policy rule create test_policy "p(5)"
    +---------+--------------------------------------+
    | Field   | Value                                |
    +---------+--------------------------------------+
    | comment | None                                 |
    | id      | 5ce7fb18-a227-447e-bec8-93e99c0052a5 |
    | name    | None                                 |
    | rule    | p(5)                                 |
    +---------+--------------------------------------+
    
    (openstack) congress policy rule list test_policy
    // ID: 5ce7fb18-a227-447e-bec8-93e99c0052a5
    // Name: None
    p(5)
    
    (openstack) exit
    $

功能

  • 待办事项

项目详情


下载文件

下载适合您平台的文件。如果您不确定选择哪个,请了解更多关于 安装包 的信息。

源分发

python-congressclient-2.0.1.tar.gz (38.8 kB 查看哈希值)

上传

构建分发

python_congressclient-2.0.1-py3-none-any.whl (40.9 kB 查看哈希值)

上传 Python 3

由以下机构支持

AWS AWS 云计算和安全赞助商 Datadog Datadog 监控 Fastly Fastly CDN Google Google 下载分析 Microsoft Microsoft PSF 赞助商 Pingdom Pingdom 监控 Sentry Sentry 错误日志 StatusPage StatusPage 状态页