forked from microsoft/planetary-computer-apis
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
130 lines (121 loc) · 3.16 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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
services:
stac:
image: pc-apis-stac
build:
context: .
dockerfile: pcstac/Dockerfile
env_file: ${PC_STAC_ENV_FILE:-./pc-stac.dev.env}
ports:
- "8081:8081"
volumes:
- ./pccommon:/opt/src/pccommon
- ./pcstac:/opt/src/pcstac
depends_on:
- database
- azurite
- redis
command: >
bash -c "pypgstac pgready && uvicorn pcstac.main:app --host 0.0.0.0 --port 8081 --reload --proxy-headers --root-path '/stac'"
tiler:
image: pc-apis-tiler
# For Mac OS M1 user, you'll need to add `platform: linux/amd64`.
# see https://github.com/developmentseed/titiler/discussions/387#discussioncomment-1643110
# platform: linux/amd64
build:
context: .
dockerfile: pctiler/Dockerfile
env_file: ${PC_TILER_ENV_FILE:-./pc-tiler.dev.env}
environment:
# Allow proxied managed identity requests in dev
- IDENTITY_ENDPOINT=http://token-proxy:8086/dev/token
- IMDS_ENDPOINT=active
ports:
- "8082:8082"
volumes:
- ./pctiler:/opt/src/pctiler
- ./pctiler/templates:/opt/src/templates
- ./pccommon:/opt/src/pccommon
depends_on:
- database
command: [ "uvicorn", "pctiler.main:app", "--host", "0.0.0.0", "--port", "8082", "--reload", "--proxy-headers" ]
funcs:
image: pc-apis-funcs
build:
context: .
dockerfile: pcfuncs/Dockerfile
env_file: ${PC_FUNCS_ENV_FILE:-./pc-funcs.dev.env}
ports:
- "8083:80"
volumes:
- ./pccommon:/home/site/pccommon
- ./pcfuncs:/home/site/wwwroot
- .:/opt/src
- ~/.azure:/home/.azure
nginx:
image: pc-apis-nginx
container_name: pc-apis-nginx
build:
context: ./nginx
dockerfile: Dockerfile
links:
- database
- azurite
- redis
depends_on:
- database
- azurite
- redis
volumes:
- ./nginx/etc/nginx:/etc/nginx
ports:
- 8080:80
database:
container_name: pc-stac-db
image: pc-apis-stac-db
build:
context: ./pgstac
dockerfile: Dockerfile
environment:
- POSTGRES_USER=username
- POSTGRES_PASSWORD=password
- POSTGRES_DB=postgis
ports:
- "5432:5432"
volumes:
- pc-apis-pgdata:/var/lib/postgresql/data
token-proxy:
image: pc-aux-token-proxy
build:
context: ./auxiliary/az-cli-proxy
dockerfile: Dockerfile
ports:
- 8086:8086
volumes:
- ./auxiliary/az-cli-proxy:/opt/src/
- ~/.azure:/root/.azure
azurite:
container_name: pcapis-azurite
image: mcr.microsoft.com/azure-storage/azurite:3.30.0
hostname: azurite
command: "azurite --silent --blobHost 0.0.0.0 --queueHost 0.0.0.0 --tableHost
0.0.0.0 -l /workspace"
ports:
- "10000:10000" # Blob
- "10001:10001" # Queue
- "10002:10002" # Table
volumes:
- pc-apis-azurite-data:/workspace
redis:
image: redis:6.2.6-buster
command: redis-server --port 6380 --requirepass devcache
ports:
- "6380:6380"
volumes:
- pc-apis-redis-data:/data
volumes:
pc-apis-pgdata:
pc-apis-azurite-data:
pc-apis-redis-data:
networks:
default:
name: pc-apis-dev-network