This repository has been archived by the owner on Feb 2, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
887347b
commit 6a9ae8a
Showing
6 changed files
with
107 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
REST Configuration | ||
================== | ||
|
||
.. todo:: | ||
|
||
Wordsmithing. | ||
|
||
|
||
.. _rest_configuration_file: | ||
|
||
Configuration File | ||
------------------ | ||
|
||
.. include:: ../examples/secure_rest_config.rst | ||
|
||
|
||
.. _rest_configuration_cli: | ||
|
||
Via CLI | ||
------- | ||
|
||
.. include:: ../examples/commissaire-server-cli.rst | ||
|
||
|
||
Example | ||
~~~~~~~ | ||
|
||
The following will run the same server as the above configuration file examples. | ||
|
||
.. note:: | ||
|
||
``--no-config`` is required when bypassing the configuration file! | ||
|
||
.. include:: ../examples/commissaire-server-cli-example.rst | ||
|
||
|
||
Authentication | ||
~~~~~~~~~~~~~~ | ||
|
||
Multiple authentication plugins can be configured via the CLI. To do this use the | ||
``--authentication-plugin`` switch multiple times. | ||
|
||
.. include:: ../examples/commissaire-server-cli-multiple-auth.rst |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
|
||
.. code-block:: shell | ||
$ commissaire-server --no-config \ | ||
--bus-uri redis://127.0.0.1:6379/ \ | ||
--bus-exchange commissaire \ | ||
--tls-pemfile /path/to/server.pem \ | ||
--listen-interface 8000 \ | ||
--authentication-plugin commissaire_http.authentication.httpbasicauth:filepath=conf/users.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
.. code-block:: shell | ||
... | ||
--authentication-plugin commissaire_http.authentication.httbasicauth:filepath=conf/users.json \ | ||
--authentication-plugin commissaire_http.authentication.keystonetokenauth:url=https://example.com |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
|
||
.. code-block:: shell | ||
usage: commissaire-server [-h] [--config-file CONFIG_FILE] [--no-config-file] | ||
[--listen-interface LISTEN_INTERFACE] | ||
[--listen-port LISTEN_PORT] | ||
[--tls-pemfile TLS_PEMFILE] | ||
[--tls-clientverifyfile TLS_CLIENTVERIFYFILE] | ||
[--authentication-plugin MODULE_NAME:key=value,..] | ||
[--bus-exchange BUS_EXCHANGE] [--bus-uri BUS_URI] | ||
optional arguments: | ||
-h, --help show this help message and exit | ||
--config-file CONFIG_FILE, -c CONFIG_FILE | ||
Full path to a JSON configuration file (command-line | ||
arguments override) | ||
--no-config-file Disregard default configuration file, if it exists | ||
--listen-interface LISTEN_INTERFACE, -i LISTEN_INTERFACE | ||
Interface to listen on | ||
--listen-port LISTEN_PORT, -p LISTEN_PORT | ||
Port to listen on | ||
--tls-pemfile TLS_PEMFILE | ||
Full path to the TLS PEM for the commissaire server | ||
--tls-clientverifyfile TLS_CLIENTVERIFYFILE | ||
Full path to the TLS file containing the certificate | ||
authorities that client certificates should be | ||
verified against | ||
--authentication-plugin MODULE_NAME:key=value,.. | ||
Authentication Plugin module and configuration. | ||
--bus-exchange BUS_EXCHANGE | ||
Message bus exchange name. | ||
--bus-uri BUS_URI Message bus connection URI. See:http://kombu.readthedo | ||
cs.io/en/latest/userguide/connections.html | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
.. code-block:: shell | ||
$ cat /etc/commissaire/commissaire.conf | ||
{ | ||
"listen-interface": "127.0.0.1", | ||
"listen-port": 8000, | ||
"tls-pemfile": "/path/to/server.pem", | ||
"bus-uri": "redis://127.0.0.1:6379/", | ||
"authentication-plugins": [{ | ||
"name": "commissaire_http.authentication.httpbasicauth", | ||
"filepath": "conf/users.json" | ||
}] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters