Initial commit
This commit is contained in:
141
templates/compose/daemons.yaml.erb
Normal file
141
templates/compose/daemons.yaml.erb
Normal file
@@ -0,0 +1,141 @@
|
||||
version: '3.6'
|
||||
|
||||
# Docker json-file rotation.
|
||||
x-logging-noisy: &fibitex-logging-noisy
|
||||
driver: json-file
|
||||
options:
|
||||
max-size: "10m"
|
||||
max-file: "3"
|
||||
|
||||
x-logging-quiet: &fibitex-logging-quiet
|
||||
driver: json-file
|
||||
options:
|
||||
max-size: "5m"
|
||||
max-file: "2"
|
||||
|
||||
x-daemon: &peatio-daemon
|
||||
image: "<%= @config['images']['peatio'] %>"
|
||||
restart: always
|
||||
logging: *fibitex-logging-noisy
|
||||
env_file:
|
||||
- ../config/peatio.env
|
||||
volumes:
|
||||
- ../config/peatio:/opt/peatio/config:ro
|
||||
|
||||
services:
|
||||
blockchain:
|
||||
<< : *peatio-daemon
|
||||
command: bash -c "ruby ./bin/link_config && bundle exec ruby lib/daemons/daemons.rb blockchain"
|
||||
|
||||
cron_job:
|
||||
<< : *peatio-daemon
|
||||
environment:
|
||||
- VAULT_TOKEN=${PEATIO_CRYPTO_VAULT_TOKEN}
|
||||
command: bash -c "ruby ./bin/link_config && bundle exec ruby lib/daemons/daemons.rb cron_job"
|
||||
|
||||
deposit:
|
||||
<< : *peatio-daemon
|
||||
environment:
|
||||
- VAULT_TOKEN=${PEATIO_CRYPTO_VAULT_TOKEN}
|
||||
command: bash -c "ruby ./bin/link_config && bundle exec ruby lib/daemons/daemons.rb deposit"
|
||||
|
||||
upstream:
|
||||
<< : *peatio-daemon
|
||||
environment:
|
||||
- VAULT_TOKEN=${PEATIO_UPSTREAM_VAULT_TOKEN}
|
||||
command: bash -c "ruby ./bin/link_config && bundle exec ruby lib/daemons/daemons.rb upstream"
|
||||
|
||||
deposit_coin_address:
|
||||
<< : *peatio-daemon
|
||||
environment:
|
||||
- VAULT_TOKEN=${PEATIO_CRYPTO_VAULT_TOKEN}
|
||||
command: bash -c "ruby ./bin/link_config && bundle exec ruby lib/daemons/amqp_daemon.rb deposit_coin_address"
|
||||
|
||||
withdraw_coin:
|
||||
<< : *peatio-daemon
|
||||
environment:
|
||||
- VAULT_TOKEN=${PEATIO_CRYPTO_VAULT_TOKEN}
|
||||
command: bash -c "ruby ./bin/link_config && bundle exec ruby lib/daemons/amqp_daemon.rb withdraw_coin"
|
||||
|
||||
influx_writer:
|
||||
<< : *peatio-daemon
|
||||
command: bash -c "ruby ./bin/link_config && bundle exec ruby lib/daemons/amqp_daemon.rb influx_writer"
|
||||
|
||||
rango:
|
||||
logging: *fibitex-logging-noisy
|
||||
restart: always
|
||||
image: "<%= @config['images']['rango'] %>"
|
||||
env_file:
|
||||
- ../config/rango.env
|
||||
|
||||
<% unless @config['finex']['enabled'] %>
|
||||
matching:
|
||||
<< : *peatio-daemon
|
||||
environment:
|
||||
- VAULT_TOKEN=${PEATIO_MATCHING_VAULT_TOKEN}
|
||||
command: bash -c "ruby ./bin/link_config && bundle exec ruby lib/daemons/amqp_daemon.rb matching"
|
||||
|
||||
order_processor:
|
||||
<< : *peatio-daemon
|
||||
environment:
|
||||
- VAULT_TOKEN=${PEATIO_MATCHING_VAULT_TOKEN}
|
||||
command: bash -c "ruby ./bin/link_config && bundle exec ruby lib/daemons/amqp_daemon.rb order_processor"
|
||||
|
||||
trade_executor:
|
||||
<< : *peatio-daemon
|
||||
environment:
|
||||
- VAULT_TOKEN=${PEATIO_MATCHING_VAULT_TOKEN}
|
||||
command: bash -c "ruby ./bin/link_config && bundle exec ruby lib/daemons/amqp_daemon.rb trade_executor"
|
||||
<% end %>
|
||||
|
||||
mailer:
|
||||
logging: *fibitex-logging-quiet
|
||||
restart: always
|
||||
image: "<%= @config['images']['barong'] %>"
|
||||
env_file:
|
||||
- ../config/barong.env
|
||||
volumes:
|
||||
- ../config/secrets:/secrets:ro
|
||||
- ../config/mailer/templates:/home/app/app/views/postmaster
|
||||
- ../config/mailer.yml:/home/app/config/mailer.yml
|
||||
- ../config/barong/seeds.yml:/home/app/config/seeds.yml
|
||||
- ../config/barong/barong.yml:/home/app/config/barong.yml
|
||||
- ../config/barong/authz_rules.yml:/home/app/config/authz_rules.yml
|
||||
- ../config/barong/management_api.yml:/home/app/config/management_api.yml
|
||||
- ../config/barong/abilities.yml:/home/app/config/abilities.yml
|
||||
command: bash -c "bin/mailer run"
|
||||
|
||||
applogic_sidekiq:
|
||||
logging: *fibitex-logging-noisy
|
||||
restart: always
|
||||
image: "<%= @utils['images']['applogic'] %>"
|
||||
env_file:
|
||||
- ../config/barong.env
|
||||
volumes:
|
||||
- ../config/applogic/management_api_v2.yml:/home/app/config/management_api_v2.yml
|
||||
- ../config/applogic/schedule.yml:/home/app/config/schedule.yml
|
||||
command: bash -c "bundle exec sidekiq"
|
||||
|
||||
barong_sidekiq:
|
||||
logging: *fibitex-logging-noisy
|
||||
restart: always
|
||||
image: "<%= @config['images']['barong'] %>"
|
||||
env_file:
|
||||
- ../config/barong.env
|
||||
volumes:
|
||||
- ../config/secrets:/secrets:ro
|
||||
- ../config/barong/seeds.yml:/home/app/config/seeds.yml
|
||||
- ../config/barong/barong.yml:/home/app/config/barong.yml
|
||||
- ../config/barong/authz_rules.yml:/home/app/config/authz_rules.yml
|
||||
- ../config/barong/management_api.yml:/home/app/config/management_api.yml
|
||||
command: bash -c "bundle exec sidekiq"
|
||||
|
||||
listener:
|
||||
logging: *fibitex-logging-noisy
|
||||
restart: always
|
||||
image: "<%= @utils['images']['applogic'] %>"
|
||||
env_file:
|
||||
- ../config/applogic.env
|
||||
volumes:
|
||||
- ../config/applogic/management_api_v2.yml:/home/app/config/management_api_v2.yml
|
||||
command: bash -c "bundle exec rake event_api_listener"
|
||||
Reference in New Issue
Block a user