version: '2.1' services: db: image: mariadb restart: always volumes: - db:/var/lib/mysql/ environment: - MYSQL_RANDOM_ROOT_PASSWORD=yes env_file: - db.env app: build: ./app restart: always volumes: - friendica:/var/www/html environment: - AUTOINSTALL=true - MAILNAME= - TZ= - LANGUAGE= env_file: - db.env depends_on: - db hostname: friendica.local cron: build: ./app restart: always volumes: - friendica:/var/www/html entrypoint: /cron.sh environment: - MAILNAME= - TZ= - LANGUAGE= env_file: - db.env depends_on: - db - app hostname: friendica.local web: image: nginx restart: always volumes: - friendica:/var/www/html:ro - ./web/nginx.conf:/etc/nginx/nginx.conf:ro depends_on: - app networks: - default - proxy-tier labels: - "traefik.backend=friendica" - "traefik.frontend.entryPoints=https,http" - "traefik.frontend.headers.STSSeconds=15768000" - "traefik.frontend.headers.STSIncludeSubdomains=false" - "traefik.frontend.headers.forceSTSHeader=true" - "traefik.friendica.frontend.rule=Host:friendica.local" - "traefik.friendica.frontend.port=80" - "traefik.enable=true" - "traefik.docker.network=proxy-tier" proxy: build: ./proxy restart: always ports: - "80:80" - "443:443" volumes: - /var/run/docker.sock:/var/run/docker.sock container_name: traefik networks: - default - proxy-tier volumes: db: friendica: networks: proxy-tier: