Setup
prevju runs as a single Docker container. You need two files and a reverse proxy for HTTPS.
docker-compose.yml
yaml
services:
prevju:
image: baeroe/prevju:latest
restart: unless-stopped
ports:
- "7738:8080"
environment:
APP_URL: "${APP_URL}"
ADMIN_EMAIL: "${ADMIN_EMAIL}"
ADMIN_PASSWORD: "${ADMIN_PASSWORD}"
volumes:
- prevju-data:/var/www/html/storage/app
volumes:
prevju-data:.env
Next to the compose file:
bash
APP_URL=https://preview.example.com
ADMIN_EMAIL=admin@example.com
ADMIN_PASSWORD=change-meAPP_URL is the public address including https://. Client links are built from it.
Start
bash
docker compose up -dOpen APP_URL and log in with ADMIN_EMAIL / ADMIN_PASSWORD. The admin user is created on the first start.
What lives where
- Data: SQLite database, uploaded sites and the generated
APP_KEYare in theprevju-datavolume. Containers can be recreated freely, the volume stays. Don't rundocker compose down -v, that deletes it. - Client links:
APP_URL/s/<slug>/, one random slug per site. - Port:
7738on the host,8080inside the container. Put a reverse proxy in front for HTTPS, see Reverse proxy. - Versions:
latestfollows every release. Pin one withimage: baeroe/prevju:0.3.1.