-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
68 lines (64 loc) · 1.7 KB
/
docker-compose.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
volumes:
node_modules:
minio_storage:
services:
spider:
build:
context: .
target: dev
env_file:
- .env
container_name: intranet-archive
environment:
ORDINAL_NUMBER: 0
VIRTUAL_HOST: app.archive.intranet.docker
VIRTUAL_PORT: "8080"
volumes:
- node_modules:/usr/local/bin/node/node_modules
- ./snapshots:/archiver/snapshots
- ./conf/node:/usr/local/bin/node
ports:
- "8090:8080"
depends_on:
minio-init:
# Wait for minio-init to complete before starting.
condition: service_completed_successfully
minio:
image: minio/minio
ports:
- "9010:9000"
- "9011:9001"
volumes:
- minio_storage:/data
environment:
MINIO_ROOT_USER: ${AWS_ACCESS_KEY_ID}
MINIO_ROOT_PASSWORD: ${AWS_SECRET_ACCESS_KEY}
command: server --console-address ":9001" /data
healthcheck:
test: timeout 5s bash -c ':> /dev/tcp/127.0.0.1/9000' || exit 1
start_period: 5s
interval: 10s
timeout: 5s
retries: 2
minio-init:
image: minio/mc
depends_on:
minio:
condition: service_healthy
entrypoint: |
/bin/sh -c "
mc config host add intranet-archive http://minio:9000 ${AWS_ACCESS_KEY_ID} ${AWS_SECRET_ACCESS_KEY}
mc mb --ignore-existing intranet-archive/${S3_BUCKET_NAME} --region eu-west-2
mc anonymous set download intranet-archive/${S3_BUCKET_NAME};
exit 0
"
cdn:
image: caddy:2-alpine
volumes:
- ./conf/local.Caddyfile:/etc/caddy/Caddyfile
environment:
S3_BUCKET_NAME: ${S3_BUCKET_NAME}
VIRTUAL_HOST: archive.intranet.docker
VIRTUAL_PORT: 2019
depends_on:
- minio