Deploys the Arcane server (control plane) as a Docker container.
- Ensures
/opt/arcaneand a.secrets/sub-directory exist with locked-down permissions. - Resolves
ENCRYPTION_KEYandJWT_SECRET:- If you pass them via inventory / vault, those win.
- Otherwise they're auto-generated on the first run via
lookup('password')and persisted under.secrets/so subsequent runs reuse the same values. Regenerating these invalidates the Arcane DB, so stability matters.
- Renders
.envanddocker-compose.ymlfrom templates. Both notify arestart arcane_serverhandler, so the container is only recreated when config actually changes on disk. - Runs
docker compose up(idempotent viacommunity.docker.docker_compose_v2) with configurable pull policy. - Waits up to
arcane_server_healthcheck_waitseconds forGET /api/healthto return200.
Every task is idempotent: re-running the playbook against a converged host is a no-op — no containers recreated, no secrets regenerated, no files rewritten.
- Docker Engine + compose plugin already installed on the target host.
- Ansible collection
community.docker >= 3.0.0.
This role intentionally does not install Docker — use geerlingguy.docker or your distro's package manager before running this role.
See defaults/main.yml for the full list with inline docs. Quick reference:
| Variable | Default | Purpose |
|---|---|---|
arcane_server_image |
ghcr.io/getarcaneapp/arcane |
Container image |
arcane_server_version |
latest |
Image tag (pin in production) |
arcane_server_port |
3552 |
Host port for the UI / API |
arcane_server_app_url |
http://{{ ansible_host }}:3552 |
APP_URL inside the container |
arcane_server_install_dir |
/opt/arcane |
Where compose + .env live |
arcane_server_data_volume |
arcane-data |
Named volume for /app/data |
arcane_server_extra_volumes |
[] |
Extra host-path mounts |
arcane_server_puid / _pgid |
"" |
Optional runtime UID/GID |
arcane_server_timezone |
UTC |
TZ for the scheduler |
arcane_server_encryption_key |
"" → auto |
Stable 32-char secret |
arcane_server_jwt_secret |
"" → auto |
Stable 48-char secret |
arcane_server_pull_policy |
always |
always / missing / never |
arcane_server_healthcheck_wait |
60 |
Post-deploy probe timeout in s |
- hosts: arcane_server
become: true
roles:
- role: giuliosavini.arcane_stack.arcane_server
vars:
arcane_server_version: "1.17.3"
arcane_server_app_url: "https://arcane.example.com"
arcane_server_extra_volumes:
- host_path: /srv/projects
container_path: /app/data/projects
- host_path: /srv/builds
container_path: /buildsMIT