diff --git a/docs/reference/client-config.md b/docs/reference/client-config.md index 2b328d46f7..56fa459342 100644 --- a/docs/reference/client-config.md +++ b/docs/reference/client-config.md @@ -11,9 +11,8 @@ weight=4 # Notary client configuration file -This document is for power users of the [Notary client](../advanced_usage.md), -or for those who are [running their own service](../running_a_service.md) who -want to facilitate CLI interaction or specify custom options. +This document is for power users of the [Notary client](../advanced_usage.md) +who want to facilitate CLI interaction or specify custom options. The configuration file for Notary client normally resides at `~/.notary/config.json`, but the path to a different configuration file can be specified using the @@ -21,38 +20,25 @@ but the path to a different configuration file can be specified using the ## Overview of the file -A configuration file consists of the following sections: +In addition to the configuration file format, please see the optional password +[environment variables](#environment-variables-optional) that the Notary client +can take for ease of use. - - - - - - - - - - - -
trust_dirTUF key and metadata directory(optional)
remote_serverremote Notary Server configuration(optional)
+Here is a full client configuration file example; please click on the top level +JSON keys to learn more about the configuration section corresponding to that key: -In addition please see the optional password [environment -variables](#environment-variables-optional) that the Notary client can take for -ease of use. -An example (full) client configuration file. - -```json +

 {
-  "trust_dir" : "~/.docker/trust",
-  "remote_server": {
+  "trust_dir" : "~/.docker/trust",
+  "remote_server": {
     "url": "https://my-notary-server.my-private-registry.com",
     "root-ca": "./fixtures/root-ca.crt",
     "tls_client_cert": "./fixtures/secure.example.com.crt",
     "tls_client_key": "./fixtures/secure.example.com.crt"
   }
 }
-```
+
## trust_dir section (optional) @@ -142,9 +128,3 @@ passphrase. |`NOTARY_ROOT_PASSPHRASE` | The root/offline key passphrase | |`NOTARY_TARGETS_PASSPHRASE` | The targets (an online) key passphrase | |`NOTARY_SNAPSHOT_PASSPHRASE` | The snapshot (an online) key passphrase | - -## Related information - -* [Notary Server Configuration File](server-config.md) -* [Notary Signer Configuration File](signer-config.md) -* [Configuration sections common to the Notary Server and Signer](common-configs.md) diff --git a/docs/reference/common-configs.md b/docs/reference/common-configs.md index f2d072831a..04f1d6692a 100644 --- a/docs/reference/common-configs.md +++ b/docs/reference/common-configs.md @@ -96,5 +96,4 @@ required parameters below, to configure it. ## Related information * [Notary Server Configuration File](server-config.md) -* [Notary Client Configuration File](client-config.md) * [Notary Signer Configuration File](signer-config.md) diff --git a/docs/reference/index.md b/docs/reference/index.md index 8d0f653a08..788b214358 100644 --- a/docs/reference/index.md +++ b/docs/reference/index.md @@ -18,7 +18,7 @@ want to facilitate CLI interaction or specify custom options. You can configure the following aspects of Notary: -* [Notary Server Configuration File](server-config.md) * [Notary Client Configuration File](client-config.md) +* [Notary Server Configuration File](server-config.md) * [Notary Signer Configuration File](signer-config.md) * [Configuration sections common to the Notary Server and Signer](common-configs.md) diff --git a/docs/reference/server-config.md b/docs/reference/server-config.md index 76ca93199d..3dedae3fd1 100644 --- a/docs/reference/server-config.md +++ b/docs/reference/server-config.md @@ -10,11 +10,8 @@ parent="mn_notary_config" # Notary server configuration file -This document is for those who are [running their own service](../running_a_service.md) who -want to facilitate CLI interaction or specify custom options. - -For full specific configuration information, see the [common configuration -file](common-configs.md) for the Notary server and signer. +This document is for those who are [running their own Notary service](../running_a_service.md) who +want to specify custom options. ## Overview @@ -22,51 +19,16 @@ A configuration file is required by Notary server, and the path to the configuration file must be specified using the `-config` option on the command line. -The configuration file consists of the following sections: +Here is a full server configuration file example; please click on the top level JSON keys to +learn more about the configuration section corresponding to that key: - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
serverHTTPS configuration(required)
trust_servicesigning service configuration(required)
storageTUF metadata storage configuration(required)
authserver authentication configuration(optional)
logginglogging configuration(optional)
reportingops/reporting configuration(optional)
- -An example (full) server configuration file. - -```json -{ - "server": { +
{
+  "server": {
     "http_addr": ":4443",
     "tls_key_file": "./fixtures/notary-server.key",
     "tls_cert_file": "./fixtures/notary-server.crt"
   },
-  "trust_service": {
+  "trust_service": {
     "type": "remote",
     "hostname": "notarysigner",
     "port": "7899",
@@ -75,11 +37,11 @@ An example (full) server configuration file.
     "tls_client_cert": "./fixtures/notary-server.crt",
     "tls_client_key": "./fixtures/notary-server.key"
   },
-  "storage": {
+  "storage": {
     "backend": "mysql",
     "db_url": "user:pass@tcp(notarymysql:3306)/databasename?parseTime=true"
   },
-  "auth": {
+  "auth": {
     "type": "token",
     "options": {
       "realm": "https://auth.docker.io/token",
@@ -88,17 +50,17 @@ An example (full) server configuration file.
       "rootcertbundle": "/path/to/auth.docker.io/cert"
     }
   },
-  "logging": {
+  "logging": {
     "level": "debug"
   },
-  "reporting": {
+  "reporting": {
     "bugsnag": {
       "api_key": "c9d60ae4c7e70c4b6c4ebd3e8056d2b8",
       "release_stage": "production"
     }
   }
 }
-```
+
## server section (required) @@ -157,7 +119,7 @@ Example: ## trust_service section (required) This section configures either a remote trust service, such as -[Notary signer](#notary-signer-configuration-file) or a local in-memory +[Notary signer](signer-config.md) or a local in-memory ED25519 trust service. Remote trust service example: @@ -298,8 +260,8 @@ configure it. **Token authentication:** -This is an implementation of the same authentication used by -[docker registry](https://github.com/docker/distribution). (JWT token-based +This is an implementation of the same authentication used by version 2 of the +[Docker registry](https://github.com/docker/distribution). (JWT token-based authentication post login.) @@ -326,6 +288,5 @@ authentication post login.) ## Related information -* [Notary Client Configuration File](client-config.md) * [Notary Signer Configuration File](signer-config.md) * [Configuration sections common to the Notary Server and Signer](common-configs.md) diff --git a/docs/reference/signer-config.md b/docs/reference/signer-config.md index 9b3fddf6d7..e9f1450bbb 100644 --- a/docs/reference/signer-config.md +++ b/docs/reference/signer-config.md @@ -11,71 +11,42 @@ parent="mn_notary_config" # Notary signer configuration file -This document is for those who are [running their own service](../running_a_service.md) who -want to facilitate CLI interaction or specify custom options. +This document is for those who are [running their own Notary service](../running_a_service.md) who +want to specify custom options. ## Overview -Notary signer [requires environment -variables](#environment-variables-required-if-using-mysql) to encrypt private -keys at rest. It also requires a configuration file, the path to which is +Notary signer [requires environment variables](#environment-variables-required-if-using-mysql) +to encrypt private keys at rest. It also requires a configuration file, the path to which is specified on the command line using the `-config` flag. -A Notary signer configuration file consists of the following sections: +Here is a full signer configuration file example; please click on the top level JSON keys to +learn more about the configuration section corresponding to that key: -
- - - - - - - - - - - - - - - - - - - - -
serverHTTPS and GRPC configuration(required)
storageTUF metadata storage configuration(required)
logginglogging configuration(optional)
reportingops/reporting configuration(optional)
- -See the [environment variables](#environment-variables-required-if-using-mysql) -to encrypt private keys at rest. - -An example (full) server configuration file. - -```json -{ - "server": { +
{
+  "server": {
     "http_addr": ":4444",
     "grpc_addr": ":7899",
     "tls_cert_file": "./fixtures/notary-signer.crt",
     "tls_key_file": "./fixtures/notary-signer.key",
     "client_ca_file": "./fixtures/notary-server.crt"
   },
-  "logging": {
+  "logging": {
     "level": 2
   },
-  "storage": {
+  "storage": {
     "backend": "mysql",
     "db_url": "user:pass@tcp(notarymysql:3306)/databasename?parseTime=true",
     "default_alias": "passwordalias1"
   },
-  "reporting": {
+  "reporting": {
     "bugsnag": {
       "api_key": "c9d60ae4c7e70c4b6c4ebd3e8056d2b8",
       "release_stage": "production"
     }
   }
 }
-```
+
## server section (required) @@ -261,5 +232,4 @@ attempts to sign data using those keys will fail. ## Related information * [Notary Server Configuration File](server-config.md) -* [Notary Client Configuration File](client-config.md) * [Configuration sections common to the Notary server and signer](common-configs.md)