This commit is contained in:
Piotr Biernat 2024-12-05 21:54:28 +01:00
parent b9b8a57a5b
commit 0173d65f9b
6 changed files with 32 additions and 38 deletions

View File

@ -2,7 +2,7 @@
## RUNNING
# $ sh deploy/start-stack.sh
# $ make up
## MAINTENANCE

View File

@ -26,12 +26,6 @@ services:
environment:
- APP_DOMAIN=eventbus.egommerce.local
# - APP_PORT=48446
labels:
- traefik.enable=true
- traefik.tcp.routers.eventbus.rule=HostSNI(`*`)
- traefik.tcp.routers.eventbus.entrypoints=rabbitmq
- traefik.tcp.routers.eventbus.service=eventbus
- traefik.tcp.services.eventbus.loadbalancer.server.port=5672
ports:
- 48446:8084
- 15672:15672

View File

@ -2,14 +2,14 @@ version: "3.9"
services:
api-gateway:
image: git.pbiernat.dev/egommerce/api-gateway:dev
image: git.ego.cloudns.be/egommerce/api-gateway:dev
environment:
- APP_DOMAIN=api-gateway
volumes:
- ./certs/api-gateway:/etc/traefik/certs
api-registry:
image: git.pbiernat.dev/egommerce/api-registry:dev
image: git.ego.cloudns.be/egommerce/api-registry:dev
environment:
- APP_DOMAIN=api-registry
- CONSUL_HTTP_TOKEN=devop
@ -17,7 +17,7 @@ services:
- ./certs/api-registry:/consul/data/certs
api-eventbus:
image: git.pbiernat.dev/egommerce/api-eventbus:dev
image: git.ego.cloudns.be/egommerce/api-eventbus:dev
environment:
- APP_DOMAIN=api-eventbus
# - RABBITMQ_NODENAME=api-eventbus
@ -26,12 +26,12 @@ services:
# - RABBITMQ_DEFAULT_PASS = passw123
api-cache:
image: git.pbiernat.dev/egommerce/api-cache:dev
image: git.ego.cloudns.be/egommerce/api-cache:dev
environment:
- PASSWORD=12345678
api-logger:
image: git.pbiernat.dev/egommerce/api-logger:dev
image: git.ego.cloudns.be/egommerce/api-logger:dev
environment:
- APP_DOMAIN=api-logger
@ -57,7 +57,7 @@ services:
# API micro-services
identity-svc:
image: git.pbiernat.dev/egommerce/identity-svc:dev
image: git.ego.cloudns.be/egommerce/identity-svc:dev
environment:
- APP_DOMAIN=identity-svc
- DATABASE_URL=postgres://postgres:12345678@postgres-db:5432/egommerce
@ -67,7 +67,7 @@ services:
- ./certs/api-gateway:/certs
basket-svc:
image: git.pbiernat.dev/egommerce/basket-svc:dev
image: git.ego.cloudns.be/egommerce/basket-svc:dev
environment:
- APP_DOMAIN=basket-svc
- AUTH_HANDLER_URL=http://identity-svc/api/v1/traefik
@ -78,7 +78,7 @@ services:
- ./certs/api-gateway:/certs
catalog-svc:
image: git.pbiernat.dev/egommerce/catalog-svc:dev
image: git.ego.cloudns.be/egommerce/catalog-svc:dev
environment:
- APP_DOMAIN=catalog-svc
- AUTH_HANDLER_URL=http://identity-svc/api/v1/traefik
@ -89,7 +89,7 @@ services:
- ./certs/api-gateway:/certs
pricing-svc:
image: git.pbiernat.dev/egommerce/pricing-svc:dev
image: git.ego.cloudns.be/egommerce/pricing-svc:dev
environment:
- APP_DOMAIN=pricing-svc
- AUTH_HANDLER_URL=http://identity-svc/api/v1/traefik
@ -100,7 +100,7 @@ services:
- ./certs/api-gateway:/certs
order-svc:
image: git.pbiernat.dev/egommerce/order-svc:dev
image: git.ego.cloudns.be/egommerce/order-svc:dev
environment:
- APP_DOMAIN=order-svc
- AUTH_HANDLER_URL=http://identity-svc/api/v1/traefik
@ -112,28 +112,28 @@ services:
# Workers (Eventbus)
basket-worker:
image: git.pbiernat.dev/egommerce/basket-worker:dev
image: git.ego.cloudns.be/egommerce/basket-worker:dev
environment:
- DATABASE_URL=postgres://postgres:12345678@postgres-db:5432/egommerce
- MONGODB_URL=mongodb://mongodb:12345678@mongo-db:27017
- EVENTBUS_URL=amqp://guest:guest@api-eventbus:5672
catalog-worker:
image: git.pbiernat.dev/egommerce/catalog-worker:dev
image: git.ego.cloudns.be/egommerce/catalog-worker:dev
environment:
- DATABASE_URL=postgres://postgres:12345678@postgres-db:5432/egommerce
- MONGODB_URL=mongodb://mongodb:12345678@mongo-db:27017
- EVENTBUS_URL=amqp://guest:guest@api-eventbus:5672
pricing-worker:
image: git.pbiernat.dev/egommerce/pricing-worker:dev
image: git.ego.cloudns.be/egommerce/pricing-worker:dev
environment:
- DATABASE_URL=postgres://postgres:12345678@postgres-db:5432/egommerce
- MONGODB_URL=mongodb://mongodb:12345678@mongo-db:27017
- EVENTBUS_URL=amqp://guest:guest@api-eventbus:5672
order-worker:
image: git.pbiernat.dev/egommerce/order-worker:dev
image: git.ego.cloudns.be/egommerce/order-worker:dev
environment:
- DATABASE_URL=postgres://postgres:12345678@postgres-db:5432/egommerce
- MONGODB_URL=mongodb://mongodb:12345678@mongo-db:27017

View File

@ -2,7 +2,7 @@ version: "3.9"
services:
api-gateway:
image: git.pbiernat.dev/egommerce/api-gateway:latest
image: git.ego.cloudns.be/egommerce/api-gateway:latest
# command:
# - '--providers.consulcatalog.refreshinterval=5s'
# FIXME ^^ only on config option: static/env/cli must be selected
@ -19,7 +19,7 @@ services:
- api-logger-network
api-registry:
image: git.pbiernat.dev/egommerce/api-registry:latest
image: git.ego.cloudns.be/egommerce/api-registry:latest
environment:
- APP_NAME=api-registry
- APP_DOMAIN
@ -32,7 +32,7 @@ services:
- api-logger-network
api-eventbus:
image: git.pbiernat.dev/egommerce/api-eventbus:latest
image: git.ego.cloudns.be/egommerce/api-eventbus:latest
environment:
# - RABBITMQ_NODENAME=api-eventbus
- RABBITMQ_ERLANG_COOKIE=rabbitmq
@ -48,7 +48,7 @@ services:
- api-logger-network
api-cache:
image: git.pbiernat.dev/egommerce/api-cache:latest
image: git.ego.cloudns.be/egommerce/api-cache:latest
environment:
- APP_NAME=api-cache
networks:
@ -56,7 +56,7 @@ services:
- api-logger-network
api-logger:
image: git.pbiernat.dev/egommerce/api-logger:latest
image: git.ego.cloudns.be/egommerce/api-logger:latest
environment:
- APP_NAME=api-logger
- APP_DOMAIN
@ -129,7 +129,7 @@ services:
# API micro-services
identity-svc:
image: git.pbiernat.dev/egommerce/identity-svc:latest
image: git.ego.cloudns.be/egommerce/identity-svc:latest
environment:
- APP_NAME=identity-svc
- APP_PATH_PREFIX=/identity
@ -150,7 +150,7 @@ services:
- mongodb-db-network
basket-svc:
image: git.pbiernat.dev/egommerce/basket-svc:latest
image: git.ego.cloudns.be/egommerce/basket-svc:latest
environment:
- APP_NAME=basket-svc
- APP_PATH_PREFIX=/basket
@ -174,7 +174,7 @@ services:
- mongodb-db-network
catalog-svc:
image: git.pbiernat.dev/egommerce/catalog-svc:latest
image: git.ego.cloudns.be/egommerce/catalog-svc:latest
environment:
- APP_NAME=catalog-svc
- APP_PATH_PREFIX=/catalog
@ -196,7 +196,7 @@ services:
- mongodb-db-network
pricing-svc:
image: git.pbiernat.dev/egommerce/pricing-svc:latest
image: git.ego.cloudns.be/egommerce/pricing-svc:latest
environment:
- APP_NAME=pricing-svc
- APP_PATH_PREFIX=/pricing
@ -218,7 +218,7 @@ services:
- mongodb-db-network
order-svc:
image: git.pbiernat.dev/egommerce/order-svc:latest
image: git.ego.cloudns.be/egommerce/order-svc:latest
environment:
- APP_NAME=order-svc
- APP_PATH_PREFIX=/order
@ -241,7 +241,7 @@ services:
# Workers (Eventbus)
basket-worker:
image: git.pbiernat.dev/egommerce/basket-worker:latest
image: git.ego.cloudns.be/egommerce/basket-worker:latest
environment:
- APP_NAME=basket-worker
- APP_KV_NAMESPACE
@ -259,7 +259,7 @@ services:
- mongodb-db-network
catalog-worker:
image: git.pbiernat.dev/egommerce/catalog-worker:latest
image: git.ego.cloudns.be/egommerce/catalog-worker:latest
environment:
- APP_NAME=catalog-worker
- DATABASE_URL
@ -275,7 +275,7 @@ services:
- mongodb-db-network
pricing-worker:
image: git.pbiernat.dev/egommerce/pricing-worker:latest
image: git.ego.cloudns.be/egommerce/pricing-worker:latest
environment:
- APP_NAME=pricing-worker
- DATABASE_URL
@ -291,7 +291,7 @@ services:
- mongodb-db-network
order-worker:
image: git.pbiernat.dev/egommerce/order-worker:latest
image: git.ego.cloudns.be/egommerce/order-worker:latest
environment:
- APP_NAME=order-worker
- DATABASE_URL

View File

@ -16,8 +16,8 @@ upstream egommerce-api-eventbus-mngmt {
server {
listen 443 ssl;
ssl_certificate /home/keedosn/workspace/golang/src/git.pbiernat.dev/egommerce/stack/deploy/certs/api-gateway/localhost.cert;
ssl_certificate_key /home/keedosn/workspace/golang/src/git.pbiernat.dev/egommerce/stack/deploy/certs/api-gateway/localhost.key;
ssl_certificate /home/keedosn/workspace/golang/src/git.ego.cloudns.be/egommerce/stack/deploy/certs/api-gateway/localhost.cert;
ssl_certificate_key /home/keedosn/workspace/golang/src/git.ego.cloudns.be/egommerce/stack/deploy/certs/api-gateway/localhost.key;
server_name egommerce.local;

View File

@ -3,7 +3,7 @@
echo "Starting egommerce docker stack..."
docker stack deploy --with-registry-auth \
--detach=true \
--detach=false \
--compose-file deploy/docker/stack.yml \
--compose-file deploy/docker/stack.prod.yml \
--compose-file deploy/docker/stack.dev.yml \