Skip to content

Commit

Permalink
docs: add nginx configuration to README
Browse files Browse the repository at this point in the history
  • Loading branch information
stonith404 committed Oct 31, 2024
1 parent 60e7daf commit 78c88f5
Showing 1 changed file with 10 additions and 15 deletions.
25 changes: 10 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,28 +85,23 @@ Required tools:

You can now sign in with the admin account on `http://localhost/login/setup`.

### Add Pocket ID as an OIDC provider
### Nginx Reverse Proxy

You can add a new OIDC client on `https://<your-domain>/settings/admin/oidc-clients`
To use Nginx in front of Pocket ID, add the following configuration to increase the header buffer size because, as SvelteKit generates larger headers.

After you have added the client, you can obtain the client ID and client secret.

You may need the following information:

- **Authorization URL**: `https://<your-domain>/authorize`
- **Token URL**: `https://<your-domain>/api/oidc/token`
- **Userinfo URL**: `https://<your-domain>/api/oidc/userinfo`
- **Certificate URL**: `https://<your-domain>/.well-known/jwks.json`
- **OIDC Discovery URL**: `https://<your-domain>/.well-known/openid-configuration`
- **Scopes**: At least `openid email`. Optionally you can add `profile` and `groups`.
```nginx
proxy_busy_buffers_size 512k;
proxy_buffers 4 512k;
proxy_buffer_size 256k;
```

### Proxy Services with Pocket ID
## Proxy Services with Pocket ID

As the goal of Pocket ID is to stay simple, we don't have a built-in proxy provider. However, you can use [OAuth2 Proxy](https://oauth2-proxy.github.io/) to add authentication to your services that don't support OIDC.

See the [guide](docs/proxy-services.md) for more information.

### Update
## Update

#### Docker

Expand Down Expand Up @@ -149,7 +144,7 @@ docker compose up -d
pm2 start caddy --name pocket-id-caddy -- run --config Caddyfile
```

### Environment variables
## Environment variables

| Variable | Default Value | Recommended to change | Description |
| ---------------------- | ----------------------- | --------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
Expand Down

0 comments on commit 78c88f5

Please sign in to comment.