From 24e7b94f08b5e94e1b7b330b1bfecbd7ef6ec857 Mon Sep 17 00:00:00 2001 From: Gao Sun Date: Mon, 9 May 2022 20:50:08 +0800 Subject: [PATCH] docs: update content (#769) --- packages/docs/docs/tutorial/README.md | 4 ++- packages/docs/docs/tutorial/configuration.md | 32 +++++++++++--------- 2 files changed, 21 insertions(+), 15 deletions(-) diff --git a/packages/docs/docs/tutorial/README.md b/packages/docs/docs/tutorial/README.md index 80de334b4..eae576470 100644 --- a/packages/docs/docs/tutorial/README.md +++ b/packages/docs/docs/tutorial/README.md @@ -4,7 +4,9 @@ sidebar_position: 1 # Introduction -🤘 Logto helps you quickly focus on everything after signing in with the following components: +🤘 Logto helps you quickly focus on everything after signing in. + +Main features: - All-platform user sign-in / sign-up experience with SDK support (SPA, iOS and Android) - Passwordless (SMS / Email) support diff --git a/packages/docs/docs/tutorial/configuration.md b/packages/docs/docs/tutorial/configuration.md index e64f91acc..e1d48fdc1 100644 --- a/packages/docs/docs/tutorial/configuration.md +++ b/packages/docs/docs/tutorial/configuration.md @@ -33,23 +33,27 @@ The `--no-inquiry` parameter is appended by default in the Docker image. ### General -| Key | Default Value | Type | Description | -| ------------------ | ------------------------ | -------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------- | -| NODE_ENV | `undefined` | 'production' | 'test' | undefined | What kind of environment that Logto runs in. If you run Logto via `npm start`, the value will always be `production`. | -| PORT | `3001` | `number` | The local port that Logto listens. | -| DB_URL | N/A | `string` | The [Postgres DSN](https://www.postgresql.org/docs/14/libpq-connect.html#id-1.7.3.8.3.6) for Logto database. | -| HTTPS_CERT_PATH | `undefined` | string | undefined | See [Enabling HTTPS](#enabling-https) for details. | -| HTTPS_KEY_PATH | `undefined` | string | undefined | Ditto. | -| TRUST_PROXY_HEADER | `false` | `boolean` | Ditto. | -| ADMIN_RESOURCE | `'https://api.logto.io'` | `string` | The resource indicator for Logto management APIs. | +:::caution +If you run Logto via `npm start`, `NODE_ENV` will always be `production`. +::: + +| Key | Default Value | Type | Description | +| ------------------ | ------------------------ | -------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------ | +| NODE_ENV | `undefined` | 'production' | 'test' | undefined | What kind of environment that Logto runs in. | +| PORT | `3001` | `number` | The local port that Logto listens. | +| DB_URL | N/A | `string` | The [Postgres DSN](https://www.postgresql.org/docs/14/libpq-connect.html#id-1.7.3.8.3.6) for Logto database. | +| HTTPS_CERT_PATH | `undefined` | string | undefined | See [Enabling HTTPS](#enabling-https) for details. | +| HTTPS_KEY_PATH | `undefined` | string | undefined | Ditto. | +| TRUST_PROXY_HEADER | `false` | `boolean` | Ditto. | +| ADMIN_RESOURCE | `'https://api.logto.io'` | `string` | The resource indicator for Logto management APIs. | ### OIDC -| Key | Default Value | Type | Description | -| --------------------- | ------------------------------- | ------------------------------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| OIDC_PRIVATE_KEY | N/A | string | undefined | The content of private key for [OIDC JWT signing](https://openid.net/specs/openid-connect-core-1_0.html#Signing).
If you'd like to set this in `.env`, you can leverage [multiline values](https://github.com/motdotla/dotenv#multiline-values) support. | -| OIDC_PRIVATE_KEY_PATH | `'./oidc-private-key.pem'` | string | undefined | The path to the private key file for [OIDC JWT signing](https://openid.net/specs/openid-connect-core-1_0.html#Signing).
Note Logto will *ignore* this value if `OIDC_PRIVATE_KEY` is not empty. | -| OIDC_ISSUER | `'http://localhost:$PORT/oidc'` | `string` | The [issuer identifier](https://openid.net/specs/openid-connect-core-1_0.html#IssuerIdentifier) for OIDC. Usually it's the URL to your OIDC provider. | +| Key | Default Value | Type | Description | +| --------------------- | ------------------------------- | ------------------------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| OIDC_PRIVATE_KEY | N/A | string | undefined | The content of private key for [OIDC JWT signing](https://openid.net/specs/openid-connect-core-1_0.html#Signing).
If you'd like to set this in `.env`, you can leverage [multiline values](https://github.com/motdotla/dotenv#multiline-values) support. | +| OIDC_PRIVATE_KEY_PATH | `'./oidc-private-key.pem'` | string | undefined | The path to the private key file for [OIDC JWT signing](https://openid.net/specs/openid-connect-core-1_0.html#Signing).
Note Logto will *ignore* this value if `OIDC_PRIVATE_KEY` is not empty. | +| OIDC_ISSUER | `'http://localhost:$PORT/oidc'` | `string` | The [issuer identifier](https://openid.net/specs/openid-connect-core-1_0.html#IssuerIdentifier) for OIDC. Usually it's the URL to your OIDC provider. | #### Supported Key Types