-
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
First attempt at shared MQTT subscription
- Loading branch information
1 parent
8ca2cb4
commit c0f9898
Showing
8 changed files
with
59 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
services: | ||
mqtt-task: | ||
build: ../ | ||
env_file: ../.env | ||
command: bundle exec rake mqtt:sub | ||
restart: always | ||
volumes: | ||
- "../log:/app/log" | ||
logging: | ||
driver: "json-file" | ||
options: | ||
max-size: "100m" | ||
environment: | ||
db_pool_size: 2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,27 @@ | ||
services: | ||
mqtt-task: | ||
build: ../ | ||
env_file: ../.env | ||
command: bundle exec rake mqtt:sub | ||
restart: always | ||
volumes: | ||
- "../log:/app/log" | ||
logging: | ||
driver: "json-file" | ||
options: | ||
max-size: "100m" | ||
environment: | ||
db_pool_size: 5 | ||
mqtt-task-main-1: | ||
extends: | ||
file: mqtt-task-common.yml | ||
service: mqtt-task | ||
environment: | ||
MQTT_CLIENT_ID: smartcitizen-api-staging-main-1 | ||
MQTT_CLEAN_SESSION: false | ||
mqtt-task-main-2: | ||
extends: | ||
file: mqtt-task-common.yml | ||
service: mqtt-task | ||
environment: | ||
MQTT_CLIENT_ID: smartcitizen-api-staging-main-2 | ||
MQTT_CLEAN_SESSION: false | ||
mqtt-task-secondary: | ||
extends: | ||
file: mqtt-task-common.yml | ||
service: mqtt-task | ||
environment: | ||
MQTT_CLIENT_ID: "smartcitizen-api-staging-secondary-${HOSTNAME}" | ||
MQTT_CLEAN_SESSION: true | ||
deploy: | ||
mode: replicated | ||
replicas: 2 | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,4 +5,4 @@ services: | |
command: bundle exec rake telnet:push | ||
restart: always | ||
environment: | ||
db_pool_size: 5 | ||
db_pool_size: 2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters