How to install authentik on a Cloud VPS
Updated 11/29/2026
authentik is an open-source identity provider for single sign-on: one account for all your applications, with OAuth2/OpenID Connect, SAML, LDAP, two-factor authentication and passkeys, plus a proxy that protects applications without a login of their own.
Running the tool on your own server means unlimited use without sending data to external services.
One-click install on cloudlinux.ro
The fastest way: authentik installs automatically at the first boot of a new server.
- Create a Cloud VPS from the control panel.
- In the configuration step, pick authentik from the app catalog.
- Start the server. The install runs in the background for a few minutes and its status shows on the server page.
- Access details and generated passwords are saved on the server in
/root/app-credentials.txt.
Manual install on any Ubuntu server
If you prefer doing it yourself, below is the exact script our automatic install runs. Execute it as root on a fresh Ubuntu server (24.04 recommended). It stops at the first error, and when it finishes you will find the access details in /root/app-credentials.txt.
export DEBIAN_FRONTEND=noninteractive
cl_firewall
curl -fsSL https://get.docker.com | sh
mkdir -p /opt/authentik/data /opt/authentik/custom-templates /opt/authentik/certs
cd /opt/authentik
ADMIN_PASS=$(openssl rand -base64 24 | tr -dc 'A-Za-z0-9' | cut -c1-20)
# The bootstrap password is read on the first start only; it then belongs to the user akadmin.
cat > .env <<ENV
PG_PASS=$(openssl rand -hex 32)
AUTHENTIK_SECRET_KEY=$(openssl rand -base64 60 | tr -d '\n')
AUTHENTIK_BOOTSTRAP_PASSWORD=${ADMIN_PASS}
AUTHENTIK_BOOTSTRAP_EMAIL=admin@${CL_HOSTNAME}
AUTHENTIK_ERROR_REPORTING__ENABLED=false
ENV
chmod 600 .env
# The official compose without the Docker socket on the worker (outposts are then deployed by hand).
cat > docker-compose.yml <<'YML'
x-authentik: &authentik
image: ghcr.io/goauthentik/server:2026.8.7
restart: unless-stopped
shm_size: 512mb
env_file: .env
environment:
AUTHENTIK_POSTGRESQL__HOST: postgresql
AUTHENTIK_POSTGRESQL__NAME: authentik
AUTHENTIK_POSTGRESQL__USER: authentik
AUTHENTIK_POSTGRESQL__PASSWORD: ${PG_PASS}
depends_on:
postgresql: { condition: service_healthy }
services:
postgresql:
image: docker.io/library/postgres:16-alpine
restart: unless-stopped
environment:
POSTGRES_DB: authentik
POSTGRES_USER: authentik
POSTGRES_PASSWORD: ${PG_PASS}
healthcheck:
test: ["CMD-SHELL", "pg_isready -d authentik -U authentik"]
interval: 10s
timeout: 5s
retries: 10
start_period: 20s
volumes:
- database:/var/lib/postgresql/data
server:
<<: *authentik
command: server
ports:
- "127.0.0.1:9000:9000"
volumes:
- ./data:/data
- ./custom-templates:/templates
worker:
<<: *authentik
command: worker
volumes:
- ./data:/data
- ./certs:/certs
- ./custom-templates:/templates
volumes:
database:
YML
docker compose pull
docker compose up -d
for i in $(seq 1 120); do curl -fs -o /dev/null http://127.0.0.1:9000/-/health/ready/ && break; sleep 5; done
curl -fs -o /dev/null http://127.0.0.1:9000/-/health/ready/
{
printf 'authentik: utilizator akadmin, parola %s\n' "$ADMIN_PASS"
printf 'Panoul de administrare: https://%s/if/admin/\n' "$CL_HOSTNAME"
printf 'Conecteaza aplicatiile din Applications > Providers (OAuth2/OpenID, SAML sau proxy). Emailul (SMTP) se seteaza cu AUTHENTIK_EMAIL__* in /opt/authentik/.env\n'
printf 'Actualizare: in /opt/authentik schimbi versiunea imaginii in docker-compose.yml, apoi docker compose pull && docker compose up -d\n'
} > /root/app-credentials.txt
cl_expose authentik 9000
You can also save this script as a recipe in your account and reuse it on any new server.
Put this guide into practice on your own VPS
EU cloud servers, billed hourly, ready in minutes, with one-click installs for dozens of apps.
See pricingRelated tutorials
How to install Memos on a Cloud VPS
Complete Memos guide: one-click install on cloudlinux.ro or manual setup on any Ubuntu server, step by step.
Updated 11/29/2026ApplicationsHow to install Open Notebook on a Cloud VPS
Complete Open Notebook guide: one-click install on cloudlinux.ro or manual setup on any Ubuntu server, step by step.
Updated 11/29/2026ApplicationsHow to install Pocket ID on a Cloud VPS
Complete Pocket ID guide: one-click install on cloudlinux.ro or manual setup on any Ubuntu server, step by step.
Updated 11/29/2026