This commit is contained in:
Andrey Ivanov 2021-05-23 16:24:10 +03:00 committed by Andrey Ivanov
parent 1c4ba38acf
commit 0f8b3ae7ea
4 changed files with 7 additions and 12 deletions

View File

@ -47,9 +47,9 @@ sender-up:
sender-down: sender-down:
docker-compose -f ./cicd/dc_sender.yml down docker-compose -f ./cicd/dc_sender.yml down
sheduler-up: scheduler-up:
docker-compose -f ./cicd/dc_sheduler.yml up -d --build docker-compose -f ./cicd/dc_sheduler.yml up -d --build
sheduler-down: scheduler-down:
docker-compose -f ./cicd/dc_sheduler.yml down docker-compose -f ./cicd/dc_sheduler.yml down
sup-up: sup-up:
@ -57,4 +57,8 @@ sup-up:
sup-down: sup-down:
docker-compose -f ./cicd/dc_sup.yml down docker-compose -f ./cicd/dc_sup.yml down
debug: sup-up calendar-up sender-up
kill: sender-down calendar-down sup-down
.PHONY: build run test lint .PHONY: build run test lint

View File

@ -22,8 +22,4 @@ services:
APP_STORAGE_SQLDBASE: calendar APP_STORAGE_SQLDBASE: calendar
APP_STORAGE_SQLUSER: calendar APP_STORAGE_SQLUSER: calendar
APP_STORAGE_SQLPASS: 12345678 APP_STORAGE_SQLPASS: 12345678
ports:
- 8888:8888
- 50051:50051
- 50053:50053
network_mode: host network_mode: host

View File

@ -20,8 +20,6 @@ services:
POSTGRES_USER: calendar POSTGRES_USER: calendar
POSTGRES_PASSWORD: 12345678 POSTGRES_PASSWORD: 12345678
POSTGRES_DB: calendar POSTGRES_DB: calendar
ports:
- 5432:5432
network_mode: host network_mode: host
rabbitmq: rabbitmq:
@ -33,7 +31,4 @@ services:
RABBITMQ_DEFAULT_USER: "rabbit" RABBITMQ_DEFAULT_USER: "rabbit"
RABBITMQ_DEFAULT_PASS: "rabbit" RABBITMQ_DEFAULT_PASS: "rabbit"
RABBITMQ_DEFAULT_VHOST: "/" RABBITMQ_DEFAULT_VHOST: "/"
ports:
- 15672:15672
- 5672:5672
network_mode: host network_mode: host

View File

@ -60,7 +60,7 @@ func New(conf Config) (*Rabbit, error) {
if err != nil { if err != nil {
return nil, fmt.Errorf("can't bind Queue on Exchange in RabbitMQ: %w", err) return nil, fmt.Errorf("can't bind Queue on Exchange in RabbitMQ: %w", err)
} }
return &Rabbit{Connection: conn, Channel: ch}, nil return &Rabbit{Connection: conn, Channel: ch, Exchange:conf.Exchange, Key: conf.Key, Queue: conf.Queue}, nil
} }
func Attach(conf Config) (*Rabbit, error) { func Attach(conf Config) (*Rabbit, error) {