Once we have the Dockerfile for building a littlefedi docker image, we can then make use of it and setup docker compose for it:
networks:
frontend:
name: frontend
external: true
services:
littlefedi:
image: littlefedi
build: ./littlefedi
environment:
- LITTLEFEDI_AUTH_MFA_ENCRYPTION_KEY=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
- LITTLEFEDI_AUTH_REQUIRE_ADMIN_MFA=true
- LITTLEFEDI_MEDIA_PROXY_SECRET=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
- LITTLEFEDI_SMTP_PASSWORD=XXXXXXXXXXXXXXXXX
ulimits:
nofile: 65536
restart: unless-stopped
networks:
- frontend
volumes:
- ./data:/data
- ./config:/config
- ./backup:/backup
Notes:
-
the
frontendnetwork is reverse-proxied throughcaddyxyzzy.cafe { reverse_proxy littlefedi:8080 } -
the
Dockerfileand the littlefedi sources are located in alittlefedisubdirectory. -
For the value of the environment variables, have a look at littlefedi's documents.
To give it all a spin:
docker compose build littlefedi
docker compose up