Skip to content

Commit 6d9f5a5

Browse files
committed
clean up useless accessories
1 parent bdf2c75 commit 6d9f5a5

File tree

1 file changed

+5
-59
lines changed

1 file changed

+5
-59
lines changed

config/deploy.yml

Lines changed: 5 additions & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -48,10 +48,10 @@ env:
4848
# SOLID_QUEUE_IN_PUMA: true
4949

5050
# Set number of processes dedicated to Solid Queue (default: 1)
51-
# JOB_CONCURRENCY: 3
51+
JOB_CONCURRENCY: 3
5252

5353
# Set number of cores available to the application on each server (default: 1).
54-
# WEB_CONCURRENCY: 2
54+
WEB_CONCURRENCY: 2
5555

5656
# Match this to any external database server to configure Active Record correctly
5757
# Use telegram_spam_sniper_bot-db for a db accessory server on same machine via local kamal docker network.
@@ -108,49 +108,19 @@ accessories:
108108
POSTGRES_USER: rails_user
109109
POSTGRES_DB: telegram_spam_sniper_bot_production
110110
secret:
111+
- RAILS_MASTER_KEY
111112
- POSTGRES_PASSWORD
112113
directories:
113114
- data:/var/lib/postgresql/data
114115
files:
115116
- db/production_setup.sql:/docker-entrypoint-initdb.d/setup.sql
116-
migrator:
117-
host: 192.168.1.188
118-
image: samrayleung/telegram_spam_sniper_bot
119-
cmd: bin/rails import:migrate_from_csv
120-
env:
121-
secret:
122-
- RAILS_MASTER_KEY
123-
volumes:
124-
- "/tmp/migration_data/db_migration_data.csv:/rails/db/data/db_migration_data.csv:ro"
125-
# Mount the SAME storage volume as the main app to access the database
126-
- "telegram_spam_sniper_bot_storage:/rails/storage"
127-
cleanup:
128-
host: 192.168.1.188
129-
image: samrayleung/telegram_spam_sniper_bot
130-
cmd: bin/rails cleanup:delete_by_csv_hash RAILS_ENV=production
131-
env:
132-
secret:
133-
- RAILS_MASTER_KEY
134117
volumes:
135118
- "/tmp/migration_data:/rails/db/data"
136-
# Mount the SAME storage volume as the main app to access the database
137-
- "telegram_spam_sniper_bot_storage:/rails/storage"
138-
exporter:
139-
host: 192.168.1.188
140-
image: samrayleung/telegram_spam_sniper_bot
141-
cmd: bin/rails export:trained_messages RAILS_ENV=production
142-
env:
143-
secret:
144-
- RAILS_MASTER_KEY
145-
volumes:
146-
- "/tmp/migration_data:/rails/db/data"
147-
# Mount the SAME storage volume as the main app to access the database
148-
- "telegram_spam_sniper_bot_storage:/rails/storage"
149119

150-
json_importer:
120+
runner:
151121
host: 192.168.1.188
152122
image: samrayleung/telegram_spam_sniper_bot
153-
cmd: bin/rails pg_migration:import_data RAILS_ENV=production
123+
cmd: sleep infinity # Keeps the container running but idle
154124
env:
155125
clear:
156126
DB_HOST: telegram_spam_sniper_bot-postgres
@@ -161,33 +131,9 @@ accessories:
161131
- POSTGRES_PASSWORD
162132
directories:
163133
- data:/var/lib/postgresql/data
164-
files:
165-
- db/production_setup.sql:/docker-entrypoint-initdb.d/setup.sql
166134
volumes:
167135
- "/tmp/migration_data:/rails/db/data"
168136

169-
json_exporter:
170-
host: 192.168.1.188
171-
image: samrayleung/telegram_spam_sniper_bot
172-
cmd: bin/rails pg_migration:export_data RAILS_ENV=production
173-
env:
174-
secret:
175-
- RAILS_MASTER_KEY
176-
volumes:
177-
- "/tmp/migration_data:/rails/db/data"
178-
# Mount the SAME storage volume as the main app to access the database
179-
- "telegram_spam_sniper_bot_storage:/rails/storage"
180-
181-
backfiller:
182-
host: 192.168.1.188
183-
image: samrayleung/telegram_spam_sniper_bot
184-
cmd: bin/rails data_migration:backfill_message_hashes
185-
env:
186-
secret:
187-
- RAILS_MASTER_KEY
188-
volumes:
189-
# Mount the SAME storage volume as the main app to access the database
190-
- "telegram_spam_sniper_bot_storage:/rails/storage"
191137
# db:
192138
# image: mysql:8.0
193139
# host: 192.168.0.2

0 commit comments

Comments
 (0)