Commit e68c5d81 authored by Nils Mittler's avatar Nils Mittler 🕵🏼
Browse files

Add configs, envs and overrides

parent 03f01a38
/docker-compose.override.yml
.env
configs/rabbitmq_plugins
docker-compose.override.yml
environments/*.env
map $http_upgrade $connection_upgrade {
default upgrade;
'' close;
}
server {
listen 80;
listen [::]:80;
server_name _;
root /var/www/frag.jetzt;
index index.html;
location / {
gzip on;
gzip_types application/javascript application/json text/css image/svg+xml;
gzip_vary on;
}
location ~ ^/(creator|participant|home|imprint|user|moderator).*$ {
gzip on;
gzip_types application/javascript application/json text/css image/svg+xml;
gzip_vary on;
alias /var/www/frag.jetzt/;
try_files $uri $uri/ /index.html;
}
location ^~ /spacy {
# proxy_pass http://frag-jetzt-spacy;
proxy_pass https://spacy.frag.jetzt;
}
location ^~ /languagetool {
rewrite ^/languagetool(.*) /v2/check$1 break;
# proxy_pass http://frag-jetzt-languagetool:8010;
proxy_pass https://lt.frag.jetzt;
}
location ^~ /deepl {
rewrite ^/deepl(.*) /v2$1 break;
proxy_pass https://api-free.deepl.com;
##########################
# SET YOUR AUTH KEY HERE #
##########################
proxy_set_header "Authorization" "DeepL-Auth-Key <auth_key-goes-here>";
}
location ^~ /api/roomsubscription {
rewrite ^/api(.*) $1 break;
proxy_pass http://fragjetzt-ws-gateway:8080;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
}
location ^~ /api/ws/websocket {
rewrite ^/api(.*) $1 break;
proxy_pass http://fragjetzt-ws-gateway:8080;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $connection_upgrade;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header X-Real-IP $remote_addr;
}
location /api {
rewrite ^/api(.*) $1 break;
proxy_pass http://fragjetzt-backend:8888;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
}
location = /favicon.ico {
alias /var/www/frag.jetzt/assets/icons/favicon.ico;
}
}
postconf -e "smtpd_relay_restrictions = permit_mynetworks, reject"
postconf -e "mynetworks = 172.0.0.0/8 127.0.0.0/8 fragjetzt-backend fragjetzt"
postconf -e "smtpd_sasl_auth_enable = no"
postconf -e "broken_sasl_auth_clients = no"
postconf -e "smtpd_recipient_restrictions = "
postconf -e "mydestination = localhost.\$mydomain, localhost, \$myhostname"
[rabbitmq_management,rabbitmq_prometheus,rabbitmq_stomp].
[rabbitmq_prometheus,rabbitmq_stomp].
version: '3'
services:
postgresql_fragjetzt:
ports:
- 127.0.0.1:5432:5432
rabbitmq:
ports:
- 127.0.0.1:5672:5672
- 127.0.0.1:15672:15672
- 127.0.0.1:61613:61613
frag-jetzt-backend:
image: git-registry.thm.de/arsnova/frag.jetzt-backend:staging
ports:
- 127.0.0.1:8888:8888
arsnova-ws-gateway:
ports:
- 127.0.0.1:8080:8080
version: '3'
services:
postgresql_fragjetzt:
restart: unless-stopped
rabbitmq:
restart: unless-stopped
frag-jetzt-backend:
restart: unless-stopped
arsnova-ws-gateway:
restart: unless-stopped
version: '3'
services:
postgresql_fragjetzt:
postgres:
image: postgres:12.1
environment:
POSTGRES_DB: fragjetzt
POSTGRES_USER: fragjetzt
POSTGRES_PASSWORD: fragjetzt
hostname: fragjetzt-postgres
container_name: fragjetzt-postgres
restart: unless-stopped
env_file: ./environments/postgres.env
volumes:
- postgresql_fragjetzt_data:/var/lib/postgresql/data
networks:
- fragjetzt
rabbitmq:
build:
context: ./rabbitmq
dockerfile: Dockerfile
environment:
RABBITMQ_DEFAULT_USER: guest
RABBITMQ_DEFAULT_PASS: guest
frag-jetzt-backend:
image: rabbitmq:3.8
hostname: fragjetzt-rabbitmq
container_name: fragjetzt-rabbitmq
restart: unless-stopped
env_file: ./environments/rabbitmq.env
networks:
- fragjetzt
expose:
- '61613'
volumes:
- ./configs/rabbitmq_plugins:/etc/rabbitmq/enabled_plugins
postfix:
image: danilsmirnov/postfix
hostname: fragjetzt-postfix
container_name: fragjetzt-postfix
restart: unless-stopped
env_file: ./environments/postfix.env
networks:
- fragjetzt
expose:
- '25'
volumes:
- ./configs/postfix:/configure.sh
backend:
image: git-registry.thm.de/arsnova/frag.jetzt-backend:master
hostname: fragjetzt-backend
container_name: fragjetzt-backend
restart: unless-stopped
depends_on:
- rabbitmq
- postgresql_fragjetzt
environment:
SPRING_RABBITMQ_HOST: rabbitmq
STOMP_RELAY_HOST: rabbitmq
SPRING_R2DBC_URL: r2dbc:postgresql://postgresql_fragjetzt/fragjetzt
SPRING_R2DBC_HOST: postgresql_fragjetzt
SPRING_R2DBC_PORT: 5432
APP_MAIL_HOST: '172.17.0.1'
APP_MAIL_SENDER_ADDRESS: ''
arsnova-ws-gateway:
- postgres
- postfix
env_file: ./environments/backend.env
networks:
- fragjetzt
ws-gateway:
image: git-registry.thm.de/arsnova/arsnova-ws-gateway:frag-jetzt
hostname: fragjetzt-ws-gateway
container_name: fragjetzt-ws-gateway
restart: unless-stopped
depends_on:
- rabbitmq
environment:
SERVER_PORT: 8080
STOMP_RELAY_HOST: rabbitmq
STOMP_RELAY_USER: guest
STOMP_RELAY_PASSWORD: guest
RABBITMQ_HOST: rabbitmq
RABBITMQ_USERNAME: guest
RABBITMQ_PASSWORD: guest
SECURITY_JWT_SECRET: secret
ALLOWEDORIGINS: 'http://localhost:4200'
env_file: ./environments/ws-gateway.env
command: /jetty/start.jar --module=http-forwarded
networks:
- fragjetzt
frontend:
image: git-registry.thm.de/arsnova/frag.jetzt:master
hostname: fragjetzt-frontend
container_name: fragjetzt-frontend
restart: unless-stopped
depends_on:
- backend
- ws-gateway
networks:
- fragjetzt
ports:
- '80:80'
volumes:
postgresql_fragjetzt_data:
networks:
fragjetzt:
name: fragjetzt
driver: bridge
# rabbitmq
STOMP_RELAY_HOST=fragjetzt-rabbitmq
SPRING_RABBITMQ_HOST=fragjetzt-rabbitmq
SPRING_RABBITMQ_USERNAME=guest
SPRING_RABBITMQ_PASSWORD=
# postgres
SPRING_R2DBC_HOST=fragjetzt-postgres
SPRING_R2DBC_PASSWORD=
# postfix
APP_MAIL_HOST=fragjetzt-postfix
APP_MAIL_SENDER_ADDRESS=
# backend
SPRING_JWT_SECRET=
SERVER_ROOT_URL=
LOGGING_LEVEL_ROOT=
MAIL_DOMAIN=
MAIL_HOST=
POSTGRES_DB=fragjetzt
POSTGRES_USER=fragjetzt
POSTGRES_PASSWORD=
RABBITMQ_DEFAULT_USER=guest
RABBITMQ_DEFAULT_PASS=
# rabbitmq
STOMP_RELAY_HOST=fragjetzt-rabbitmq
STOMP_RELAY_USER=guest
STOMP_RELAY_PASSWORD=
RABBITMQ_HOST=fragjetzt-rabbitmq
RABBITMQ_USERNAME=guest
RABBITMQ_PASSWORD=
# jwt
SECURITY_JWT_SECRET=
# ws-gateway
SERVER_PORT=8080
LOGGING_LEVEL_ROOT=
ALLOWEDORIGINS=
backend:
ports:
- '127.0.0.1:8888:8888'
backend:
# USE NODE:16 AS IT IS AVAILABLE ANYWAY
image: node:16
hostname: fragjetzt-backend-disabled
container_name: fragjetzt-backend-disabled
restart: 'no'
depends_on: []
entrypoint: '/bin/echo'
command: 'Service disabled.'
frontend:
ports:
- '127.0.0.1:80:80'
frontend:
# USE NODE:16 AS IT IS AVAILABLE ANYWAY
image: node:16
hostname: fragjetzt-frontend-disabled
container_name: fragjetzt-frontend-disabled
restart: 'no'
depends_on: []
entrypoint: '/bin/echo'
command: 'Service disabled.'
rabbitmq:
image: rabbitmq:3.8-management
ports:
- '127.0.0.1:15672:15672'
ws-gateway:
ports:
- '127.0.0.1:8080:8080'
ws-gateway:
# USE NODE:16 AS IT IS AVAILABLE ANYWAY
image: node:16
hostname: fragjetzt-ws-gateway-disabled
container_name: fragjetzt-ws-gateway-disabled
restart: 'no'
depends_on: []
entrypoint: '/bin/echo'
command: 'Service disabled.'
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment