Skip to content

Commit

Permalink
Update config docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Cito committed Dec 5, 2023
1 parent 69d7089 commit b68a31e
Show file tree
Hide file tree
Showing 3 changed files with 53 additions and 4 deletions.
14 changes: 12 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@

[![tests](https://github.com/ghga-de/access-request-service/actions/workflows/tests.yaml/badge.svg)](https://github.com/ghga-de/access-request-service/actions/workflows/unit_and_int_tests.yaml)
[![tests](https://github.com/ghga-de/access-request-service/actions/workflows/tests.yaml/badge.svg)](https://github.com/ghga-de/access-request-service/actions/workflows/tests.yaml)
[![Coverage Status](https://coveralls.io/repos/github/ghga-de/access-request-service/badge.svg?branch=main)](https://coveralls.io/github/ghga-de/access-request-service?branch=main)

# Access Request Service
Expand Down Expand Up @@ -103,6 +103,16 @@ The service requires the following configuration parameters:
```


- **`kafka_security_protocol`** *(string)*: Protocol used to communicate with brokers. Valid values are: PLAINTEXT, SSL. Must be one of: `["PLAINTEXT", "SSL"]`. Default: `"PLAINTEXT"`.

- **`kafka_ssl_cafile`** *(string)*: Certificate Authority file path containing certificates used to sign broker certificates. If a CA not specified, the default system CA will be used if found by OpenSSL. Default: `""`.

- **`kafka_ssl_certfile`** *(string)*: Optional filename of client certificate, as well as any CA certificates needed to establish the certificate's authenticity. Default: `""`.

- **`kafka_ssl_keyfile`** *(string)*: Optional filename containing the client private key. Default: `""`.

- **`kafka_ssl_password`** *(string)*: Optional password to be used for the client private key. Default: `""`.

- **`db_connection_str`** *(string, format: password)*: MongoDB connection string. Might include credentials. For more information see: https://naiveskill.com/mongodb-connection-string/.


Expand All @@ -129,7 +139,7 @@ The service requires the following configuration parameters:

- **Items** *(string)*

- **`auth_check_claims`** *(object)*: A dict of all GHGA internal claims that shall be verified. Default: `{"email": null, "exp": null, "iat": null, "name": null}`.
- **`auth_check_claims`** *(object)*: A dict of all GHGA internal claims that shall be verified. Default: `{"name": null, "email": null, "iat": null, "exp": null}`.

- **`auth_map_claims`** *(object)*: A mapping of claims to attributes in the GHGA auth context. Can contain additional properties. Default: `{}`.

Expand Down
38 changes: 36 additions & 2 deletions config_schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,40 @@
"title": "Kafka Servers",
"type": "array"
},
"kafka_security_protocol": {
"default": "PLAINTEXT",
"description": "Protocol used to communicate with brokers. Valid values are: PLAINTEXT, SSL.",
"enum": [
"PLAINTEXT",
"SSL"
],
"title": "Kafka Security Protocol",
"type": "string"
},
"kafka_ssl_cafile": {
"default": "",
"description": "Certificate Authority file path containing certificates used to sign broker certificates. If a CA not specified, the default system CA will be used if found by OpenSSL.",
"title": "Kafka Ssl Cafile",
"type": "string"
},
"kafka_ssl_certfile": {
"default": "",
"description": "Optional filename of client certificate, as well as any CA certificates needed to establish the certificate's authenticity.",
"title": "Kafka Ssl Certfile",
"type": "string"
},
"kafka_ssl_keyfile": {
"default": "",
"description": "Optional filename containing the client private key.",
"title": "Kafka Ssl Keyfile",
"type": "string"
},
"kafka_ssl_password": {
"default": "",
"description": "Optional password to be used for the client private key.",
"title": "Kafka Ssl Password",
"type": "string"
},
"db_connection_str": {
"description": "MongoDB connection string. Might include credentials. For more information see: https://naiveskill.com/mongodb-connection-string/",
"examples": [
Expand Down Expand Up @@ -110,10 +144,10 @@
},
"auth_check_claims": {
"default": {
"name": null,
"email": null,
"exp": null,
"iat": null,
"name": null
"exp": null
},
"description": "A dict of all GHGA internal claims that shall be verified.",
"title": "Auth Check Claims",
Expand Down
5 changes: 5 additions & 0 deletions example_config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,13 @@ db_name: dev-db
docs_url: /docs
download_access_url: http://127.0.0.1:8080/download-access
host: 127.0.0.1
kafka_security_protocol: PLAINTEXT
kafka_servers:
- kafka:9092
kafka_ssl_cafile: ''
kafka_ssl_certfile: ''
kafka_ssl_keyfile: ''
kafka_ssl_password: ''
log_level: info
notification_event_topic: notifications
notification_event_type: notification
Expand Down

0 comments on commit b68a31e

Please sign in to comment.