How to Deploy Outline Wiki with OIDC Authentication
Outline gives your team a Notion-like wiki on your own server. Here is how to deploy it with single sign-on through OIDC.
Outline is the best open-source wiki for teams. It has real-time collaborative editing, markdown support, nested collections, and full-text search. It looks and works like Notion but runs on your server. Here is the complete deployment guide with OIDC authentication.
Step 1: Generate the Secret Key and Utility Secret
openssl rand -hex 32
# Use the output as SECRET_KEY
openssl rand -hex 32
# Use the output as UTILS_SECRETStep 2: Create the Docker Compose File
services:
outline-db:
image: postgres:16-alpine
container_name: outline-db
restart: unless-stopped
volumes:
- ./db:/var/lib/postgresql/data
environment:
POSTGRES_USER: outline
POSTGRES_PASSWORD: outline_password
POSTGRES_DB: outline
outline-redis:
image: redis:7-alpine
container_name: outline-redis
restart: unless-stopped
outline:
image: outlinewiki/outline:latest
container_name: outline
restart: unless-stopped
ports:
- "127.0.0.1:3000:3000"
volumes:
- ./data:/var/lib/outline/data
environment:
DATABASE_URL: postgres://outline:outline_password@outline-db:5432/outline
DATABASE_URL_TEST: postgres://outline:outline_password@outline-db:5432/outline-test
REDIS_URL: redis://outline-redis:6379
URL: https://wiki.yourdomain.com
SECRET_KEY: your_generated_secret_key
UTILS_SECRET: your_generated_utils_secret
PORT: 3000
OIDC_CLIENT_ID: outline
OIDC_CLIENT_SECRET: outline_oidc_secret
OIDC_AUTH_URI: https://auth.yourdomain.com/api/oidc/authorization
OIDC_TOKEN_URI: https://auth.yourdomain.com/api/oidc/token
OIDC_USERINFO_URI: https://auth.yourdomain.com/api/oidc/userinfo
OIDC_DISPLAY_NAME: Authelia
OIDC_SCOPES: openid profile email
OIDC_USERNAME_CLAIM: preferred_username
OIDC_DISPLAY_NAME_CLAIM: name
OIDC_EMAIL_CLAIM: email
FORCE_HTTPS: "true"
ENABLE_UPDATES: "false"
FILE_STORAGE: local
FILE_STORAGE_LOCAL_ROOT_DIR: /var/lib/outline/data
depends_on:
- outline-db
- outline-redisStep 3: Configure OIDC in Authelia
Add Outline as an OIDC client in Authelia's configuration:
identity_providers:
oidc:
clients:
- id: outline
secret: outline_oidc_secret
public: false
authorization_policy: one_factor
redirect_uris:
- https://wiki.yourdomain.com/auth/oidc.callback
scopes:
- openid
- profile
- emailStep 4: Configure Storage for Attachments
Outline stores file attachments in S3-compatible storage. For local storage, set FILE_STORAGE to local as shown above. For S3-compatible object storage like RustFS:
AWS_ACCESS_KEY_ID: your_access_key
AWS_SECRET_ACCESS_KEY: your_secret_key
AWS_REGION: ap-southeast-1
AWS_S3_UPLOAD_BUCKET_URL: https://s3.yourdomain.com
AWS_S3_UPLOAD_BUCKET_NAME: outline
AWS_S3_FORCE_PATH_STYLE: "true"
FILE_STORAGE: s3Step 5: Start and Configure
docker compose up -dOpen https://wiki.yourdomain.com. Outline redirects to your Authelia login page. After authentication, Outline creates the first user account automatically. This first user becomes the admin.
Create collections for each team. Start writing documentation. Your entire company knowledge base is now on your server, in your control, searchable, and backed up.
If OIDC callbacks and S3 bucket configuration sound like a language you do not speak, VPS1 deploys Outline with SSO and storage. Your team gets a Notion-quality wiki. You get the confidence that company knowledge lives on company hardware.
More articles
How to Deploy BTCPay Server: Accept Bitcoin Payments with Zero Platform Fees
BTCPay Server lets you accept Bitcoin and Lightning payments with no platform fees. Only standard Bitcoin network fees apply. Here is how to deploy it with Docker Compose.
Self-Hosted Crypto Payment Processors: BTCPay Server, Bitcart, and SHKeeper Compared
Accept Bitcoin and cryptocurrency payments directly with no platform fees, no intermediaries, and no KYC. Here is how BTCPay Server, Bitcart, and SHKeeper compare.
How to Deploy SHKeeper: Accept Crypto Payments with WooCommerce in 30 Minutes
SHKeeper supports Bitcoin, Ethereum, USDT, USDC, and 19+ cryptocurrencies with a free WooCommerce plugin. Zero platform fees -- only standard network fees apply.