Cozy Cloud
Cozy is a human-centric, open source and french personal cloud that gather all your data for more services, control and security.
Directory Structure
- .env
- docker-compose.yml
docker-compose.yml
version: "3.8"
name: cozy
services:
# Database
couchdb:
image: couchdb:3.3
restart: unless-stopped
env_file: .env
volumes:
- ./volumes/couchdb/data:/opt/couchdb/data
healthcheck:
test:
[
"CMD",
"curl",
"-f",
"${COUCHDB_PROTOCOL}://${COUCHDB_USER}:${COUCHDB_PASSWORD}@${COUCHDB_HOST}:${COUCHDB_PORT}/_up",
]
interval: 10s
timeout: 5s
retries: 3
start_period: 30s
# Cozy Stack
stack:
image: cozy/cozy-stack
pull_policy: always
restart: unless-stopped
env_file: .env
depends_on:
- couchdb
healthcheck:
test: '[ "$(curl -fsSL http://localhost:8080/status | jq -r .status)" = "OK" ]'
interval: 10s
timeout: 5s
retries: 3
start_period: 30s
volumes:
- ./volumes/cozy-stack/data:/var/lib/cozy/data
- ./volumes/cozy-stack/config:/etc/cozy/
- ./files/cozy.yml:/etc/cozy/cozy.yml
# Reverse Proxy
caddy:
image: caddy:2.7
restart: unless-stopped
cap_add:
- NET_ADMIN
depends_on:
- stack
volumes:
- ./volumes/caddy/data:/data
- ./volumes/caddy/etc:/etc/caddy
- ./files/Caddyfile:/etc/caddy/Caddyfile
ports:
- "80:80"
- "443:443"
- "443:443/udp".env
## Global configuration
#######################
# The base domain for all your instances
DOMAIN=domain.example
## Reverse proxy
################
# The email address used to generate let's Encrypt certificates on-the-fly
ACME_EMAIL=your.email@domain.example
# CouchDB
##########
COUCHDB_PROTOCOL=http
COUCHDB_HOST=couchdb
COUCHDB_PORT=5984
COUCHDB_USER=cozy
COUCHDB_PASSWORD=SomeRandomlyGeneratedPassword
# Stack
#######
# Admin passphrase for all administrative commands
# Should be set on first container launch to define the password
# If undefined on first start, a random password will be chosen and shown in logs
# You can remove this line and restart container if you want cozy-stack to
# ask for admin password on each command line call
COZY_ADMIN_PASSPHRASE=AnotherRandomlyGeneratedPassword
# Application subdomain type for each cozy.
# could be nested (https://<app>.<instance>.<domain>)
# or flat (https://<instance>-<app>.<domain>)
COZY_SUBDOMAIN_TYPE=flat
# Mail
START_EMBEDDED_POSTFIX=true
MAIL_HOST=localhost
MAIL_PORT=25
MAIL_USERNAME=""
MAIL_PASSWORD=""
MAIL_DISABLE_TLS=true
MAIL_USE_SSL=false
MAIL_SKIP_CERTIFICATE_VALIDATION=false
MAIL_LOCAL_NAME=localhostResources
Website: https://cozy.io/
GitHub: https://github.com/cozy/cozy-stack
Docker Hub: https://hub.docker.com/r/cozy/cozy-stack
Configuration: https://docs.cozy.io/en/tutorials/selfhosting/docker/