Files
umami/SETUP.md
2026-02-17 00:59:45 -03:00

57 lines
1.6 KiB
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# Umami analytics stack setup
Deploy this stack in Portainer as **Stack → Add stack → Build method: Git repository**, then use the web editor and the steps below.
## 1. Create the external volume (once)
If the volume does not exist yet, create it on the host (or the node where the stack runs):
```bash
docker volume create umami-db-data
```
The compose file expects this name; the stack will fail to start if the volume is missing.
## 2. Generate secrets
Run these commands and paste each output into the corresponding Portainer env var (no quotes):
**APP_SECRET:**
```bash
openssl rand -hex 32
```
**POSTGRES_PASSWORD:**
```bash
openssl rand -hex 32
```
Use different values for each.
## 3. Environment variables in Portainer
In Portainer: **Stack → your stack → Editor → Add/Edit environment variables** (or the “Web editor” env vars section). Paste the block below, then replace the `REPLACE_ME` values with the outputs from step 2.
```
POSTGRES_DB=umami
POSTGRES_USER=umami
POSTGRES_PASSWORD=REPLACE_ME
APP_SECRET=REPLACE_ME
```
Create the external volume(s) (step 1) before the first deploy if they do not exist.
## 4. Traefik Host rule
The stack is configured for **analytics.mifi.holdings**. If you deploy elsewhere, edit `docker-compose.yml` and change the Traefik label:
- `traefik.http.routers.umami.rule=Host(\`your-domain.example.com\`)`
Then redeploy the stack (and reload Traefik if needed).
## 5. First login
After the stack is running, open the app at your configured host (e.g. https://analytics.mifi.holdings). Create the admin account in the Umami UI; there are no default credentials.