* backend: refactor swarm support to also support podman (#260) - implement podman support as subclass of swarm deployment - podman is used when 'RUNTIME=podman' env var is set - podman socket is mapped instead of docker socket - podman-compose is used instead of docker-compose (though docker-compose works with podman, it does not support secrets, but podman-compose does) - separate cli utils into SwarmRunner and PodmanRunner which extends it - using config.yaml and config.env, both copied from sample versions - work on simplifying config: add docker-compose.podman.yml and docker-compose.swarm.yml and signing and debug configs in ./configs - add {build,run,stop}-{swarm,podman}.sh in scripts dir - add init-configs, only copy if configs don't exist - build local image use current version of podman, to support both podman 3.x and 4.x - additional fixes for after testing podman on centos - docs: update Deployment.md to cover swarm, podman, k8s deployment
75 lines
1.4 KiB
YAML
75 lines
1.4 KiB
YAML
version: '3.8'
|
|
|
|
services:
|
|
backend:
|
|
build: ./backend
|
|
image: ${REGISTRY}webrecorder/browsertrix-backend:latest
|
|
|
|
secrets:
|
|
- shared_job_config.yaml
|
|
|
|
env_file:
|
|
- ./configs/config.env
|
|
|
|
depends_on:
|
|
- minio
|
|
- mongo
|
|
|
|
environment:
|
|
- CRAWLER_FQDN_SUFFIX=
|
|
- JOB_IMAGE=${REGISTRY}webrecorder/browsertrix-backend:latest
|
|
- SHARED_JOB_CONFIG=shared_job_config.yaml
|
|
|
|
frontend:
|
|
build: ./frontend
|
|
image: ${REGISTRY}webrecorder/browsertrix-frontend:latest
|
|
ports:
|
|
- 9871:80
|
|
|
|
depends_on:
|
|
- backend
|
|
- minio
|
|
|
|
environment:
|
|
- BACKEND_HOST=backend
|
|
- CRAWLER_FQDN_SUFFIX=
|
|
- CRAWLER_SVC_SUFFIX=_crawler
|
|
|
|
mongo:
|
|
image: mongo
|
|
volumes:
|
|
- btrix-mongo-data:/data/db
|
|
|
|
env_file:
|
|
- ./configs/config.env
|
|
|
|
|
|
minio:
|
|
image: minio/minio
|
|
#command: ["server", "/data", "--console-address", ":9001"]
|
|
|
|
entrypoint: "/bin/sh"
|
|
# auto-create bucket via existing dir (only for single-node mode)
|
|
command: ["-c", "mkdir -p /data/$$MINIO_BUCKET; /usr/bin/docker-entrypoint.sh server /data --console-address :9001"]
|
|
|
|
volumes:
|
|
- btrix-minio-data:/data
|
|
|
|
env_file:
|
|
- ./configs/config.env
|
|
|
|
restart: always
|
|
|
|
volumes:
|
|
btrix-redis-data:
|
|
btrix-mongo-data:
|
|
btrix-minio-data:
|
|
|
|
networks:
|
|
default:
|
|
name: btrix-net
|
|
|
|
secrets:
|
|
shared_job_config.yaml:
|
|
file: ./configs/config.yaml
|