-
Notifications
You must be signed in to change notification settings - Fork 2
/
docker-compose.dev.yml
67 lines (63 loc) · 1.75 KB
/
docker-compose.dev.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
# SPDX-FileCopyrightText: 2019 Free Software Foundation Europe e.V.
#
# SPDX-License-Identifier: GPL-3.0-or-later
version: "3"
services:
reuse-api:
container_name: reuse-api
image: reuse-api
build:
context: .
target: dev
restart: always
ports:
- "27000:8000"
environment:
FLASK_APP: "/home/fsfe/reuse_api"
FLASK_RUN_HOST: "0.0.0.0"
FLASK_RUN_PORT: "8000"
FORMS_FILE: "${FORMS_FILE:-/home/fsfe/forms/repos.json}"
FORMS_URL: "http://forms:8080/email"
NB_REPOSITORY_BY_PAGES: 100
REUSE_API: "reuse-api-worker"
SECRET_KEY: "${SECRET_KEY:-verysecretkey}"
ADMIN_KEY: "${ADMIN_KEY:-myadminkey}"
SQLALCHEMY_DATABASE_URI: "postgresql://fsfe:fsfe@reuse-db/reuse"
SSH_KEY_PATH: "${SSH_KEY_PATH:-~/.ssh/test_ed25519}"
SSH_KNOW_HOST_PATH: "${SSH_KNOW_HOST_PATH:-~/.ssh/known_hosts}"
SSH_PORT: 22
SSH_USER: "root"
command: "flask --debug run"
volumes:
- ./reuse_api:/home/fsfe/reuse_api
- ./api-worker/worker-setup/files:/home/fsfe/.ssh:rw
- ./forms/store/reuse-api/:/home/fsfe/forms/:ro
depends_on:
- reuse-db
networks:
- default
- forms_default
reuse-db:
container_name: reuse-db
image: bitnami/postgresql:13
environment:
POSTGRESQL_USERNAME: fsfe
POSTGRESQL_PASSWORD: fsfe
POSTGRESQL_DATABASE: reuse
ports:
- "27001:5432"
restart: always
reuse-api-worker:
container_name: reuse-api-worker
build:
context: api-worker
image: reuse-api-worker
restart: always
expose:
- "22"
# Docker in container uses the host's Docker socket
volumes:
- /var/run/docker.sock:/var/run/docker.sock
networks:
forms_default:
external: true