From f0c63245a21e144f4b0c93e12e1ed8201eef2a5a Mon Sep 17 00:00:00 2001 From: arthurtemporim Date: Mon, 26 Oct 2020 18:29:47 -0300 Subject: [PATCH 01/13] Create webchat service in docker-compose, update make run-webchat command and configure webchat docker Signed-off-by: arthurtemporim --- Makefile | 5 +- docker-compose.yml | 10 +++ modules/webchat/index.html | 2 +- modules/webchat/index.min.js | 129 +++++++++++++++++++++++++++++++++++ 4 files changed, 142 insertions(+), 4 deletions(-) create mode 100644 modules/webchat/index.min.js diff --git a/Makefile b/Makefile index 774d68a9..07dc24e0 100644 --- a/Makefile +++ b/Makefile @@ -62,11 +62,10 @@ run-webchat: $(info Executando Bot com Webchat.) $(info ) docker-compose run -d --rm --service-ports bot-webchat + docker-compose up -d webchat $(info ) - $(info Caso o FIREFOX não seja iniciado automáticamente, abra o seguinte arquivo com seu navegador:) - $(info modules/webchat/index.html) + $(info Acesse o WEBCHAT em: http://localhost:5010) $(info ) - firefox modules/webchat/index.html run-telegram: docker-compose run -d --rm --service-ports bot_telegram make telegram diff --git a/docker-compose.yml b/docker-compose.yml index b02c12ec..e71b7d04 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -125,6 +125,16 @@ services: - env/rabbitmq-consumer.env command: python3 /opt/scripts/consume_bot_messages.py + + # ============================ Webchat Page ================================= + # A container to run webchat html page + webchat: + image: nginx + ports: + - 5010:80 + volumes: + - ./modules/webchat:/usr/share/nginx/html + # ============================ Telegram Bot ================================= # Specific Rasa bot integrated with Telegram. bot_telegram: diff --git a/modules/webchat/index.html b/modules/webchat/index.html index a1c14504..9db54112 100644 --- a/modules/webchat/index.html +++ b/modules/webchat/index.html @@ -6,7 +6,7 @@

Seja bem vindo ao BOILERPLATE integrado com webchat

Você deve ver uma bola azul no canto inferior direito do seu navegador.
- +