start consuming
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Torma Kristóf 2020-08-06 17:33:57 +02:00
parent 858c95220e
commit caf9e1c0f3
Signed by: tormakris
GPG Key ID: DC83C4F2C41B1047
2 changed files with 20 additions and 4 deletions

View File

@ -1,3 +1,5 @@
version: '3.4'
networks:
guard:
external: false
@ -22,16 +24,29 @@ services:
restart: always
networks:
- guard
volumes:
- ./artemis-volume:/var/lib/artemis-instance
guard-service:
image: registry.kmlabz.com/birbnetes/guard-service
restart: always
depends_on:
- activemq
- postgres
- rabbitmq
environment:
SENTRY_DSN: "https://5c925c5a898b4b7d82ee51cd544de623@sentry.kmlabz.com/3"
GUARD_RABBITMQ_HOSTNAME: rabbitmq
GUARD_RABBITMQ_USERNAME: rabbitmq
GUARD_RABBITMQ_PASSWORD: rabbitmq
GUARD_RABBITMQ_EXCHANGE: "sample"
GUARD_MQTT_HOSTNAME: activemq
GUARD_MQTT_PORT: "1883"
GUARD_MQTT_USERNAME: artemis
GUARD_MQTT_PASSWORD: artemis
GUARD_MQTT_TOPIC: "command"
networks:
- guard
ports:
- "127.0.0.1:8080:8080"
- "127.0.0.1:8080:8080"
input-service:
image: mockserver/mockserver
command: -logLevel DEBUG -serverPort 80

View File

@ -49,6 +49,7 @@ def setup_rabbit() -> None:
exclusive=True).method.queue
channel.queue_bind(exchange=config.RABBIT_EXCHANGE, queue=queue)
channel.basic_consume(queue=queue, on_message_callback=on_message, auto_ack=True)
channel.start_consuming()
def on_message(channel, method_frame, header_frame, body):