-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
43 lines (40 loc) · 1.01 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
version: '3'
services:
redis:
image: redis:6
networks:
- ne-student-network
container_name: studa-redis
volumes:
- ./redis-data:/var/lib/redis
- ./redis.conf:/usr/local/etc/redis/redis.conf
command:
redis-server --requirepass ${REDIS_PASSWORD}
postgres:
image: postgres:12-alpine
networks:
- ne-student-network
container_name: studa-postgres
environment:
POSTGRES_PASSWORD: ${DB_PASSWORD}
POSTGRES_USER: ${DB_USER}
POSRGRES_DB: nestudent
api:
image: docker.pkg.github.com/ne-student/api/api
# build: .
container_name: api
networks:
- ne-student-network
environment:
PORT: 5505
HOST: 0.0.0.0
DATABASE_URL: postgresql://${DB_USER}:${DB_PASSWORD}@studa-postgres/nestudent
RUST_LOG: actix,ne-student-api
TOKEN_SECRET: ${TOKEN_SECRET}
REDIS_URL: redis://:${REDIS_PASSWORD}@studa-redis
ports:
- ${PORT}:5505
depends_on:
- postgres
networks:
ne-student-network: