Add prod docker files without db
Cette révision appartient à :
Parent
f0c4eee826
révision
3d0f600f0b
2 fichiers modifiés avec 28 ajouts et 0 suppressions
19
deploy/docker-compose.postgres-prod.yml
Fichier normal
19
deploy/docker-compose.postgres-prod.yml
Fichier normal
|
@ -0,0 +1,19 @@
|
|||
version: '3'
|
||||
services:
|
||||
pantsu:
|
||||
build:
|
||||
context: ..
|
||||
dockerfile: deploy/Dockerfile
|
||||
command: ./deploy/init.sh
|
||||
env_file:
|
||||
- postgres-prod.env
|
||||
environment:
|
||||
- PANTSU_INTERNAL_PORT=${PANTSU_INTERNAL_PORT}
|
||||
ports:
|
||||
# 0.0.0.0 makes it accessible to the network
|
||||
# You may want to remove it to make pantsu available only
|
||||
# to localhost
|
||||
- 0.0.0.0:${PANTSU_EXTERNAL_PORT}:${PANTSU_INTERNAL_PORT}
|
||||
volumes:
|
||||
- "${GOPATH}:/go/"
|
||||
- "./..:/nyaa"
|
9
deploy/postgres-prod.env
Fichier normal
9
deploy/postgres-prod.env
Fichier normal
|
@ -0,0 +1,9 @@
|
|||
POSTGRES_USER=nyaapantsu
|
||||
POSTGRES_PASSWORD=nyaapantsu
|
||||
POSTGRES_DB=nyaapantsu
|
||||
|
||||
PANTSU_DBTYPE=postgres
|
||||
# TODO Would prefer to use the line below but docker doesn't seem to accept
|
||||
# that.
|
||||
#PANTSU_DBPARAMS=host=pantsu_db user=${POSTGRES_USER} dbname=${POSTGRES_DB} sslmode=disable password=${POSTGRES_PASSWORD}
|
||||
PANTSU_DBPARAMS=host=localhost user=nyaapantsu dbname=nyaapantsu sslmode=disable password=nyaapantsu
|
Référencer dans un nouveau ticket