- Add db.py PostgreSQL abstraction layer (connection, upsert, table mgmt) - Replace sqlite3 with psycopg2 in: live_candle_fetcher, resampler, data_fetcher, fetch_history, import_csv, indicators, base_strategy - Sanitize table names (colons -> underscores) for PostgreSQL compat - Replace INSERT OR REPLACE with ON CONFLICT upserts - Replace pandas to_sql() with batch upsert_candles() - Add scripts: resampler_loop, gap_detector, backup_runner, cron_scheduler - Add migrate_sqlite_to_pg.py for one-time data migration - Add Dockerfile, docker-compose.yml, supervisord.conf - Add postgres/postgresql.conf tuned for 4GB RAM (Synology DS1513+) - Add .dockerignore, .env.docker.example, secrets template - Update requirements.txt (psycopg2-binary), .gitignore - Add MIGRATION_PLAN.md with full plan and todo list
39 lines
1.3 KiB
Plaintext
39 lines
1.3 KiB
Plaintext
[supervisord]
|
|
nodaemon=true
|
|
|
|
[program:live_candle_fetcher]
|
|
command=python live_candle_fetcher.py --coins BTC ETH SOL BNB HYPE SUI xyz:BRENTOIL xyz:CL xyz:GOLD xyz:SILVER mkts:USTECH xyz:XYZ100 --log-level normal
|
|
autostart=true
|
|
autorestart=true
|
|
stdout_logfile=/app/_logs/live_candle_fetcher.log
|
|
stderr_logfile=/app/_logs/live_candle_fetcher.log
|
|
stdout_logfile_maxbytes=10MB
|
|
stdout_logfile_backups=3
|
|
|
|
[program:resampler_loop]
|
|
command=python scripts/resampler_loop.py --coins BTC ETH SOL BNB HYPE SUI xyz:BRENTOIL xyz:CL xyz:GOLD xyz:SILVER mkts:USTECH xyz:XYZ100 --timeframes 3m 5m 15m 30m 1h 2h 4h 8h 12h 1d 3d 1w 1M 148m 37m --log-level normal
|
|
autostart=true
|
|
autorestart=true
|
|
stdout_logfile=/app/_logs/resampler.log
|
|
stderr_logfile=/app/_logs/resampler.log
|
|
stdout_logfile_maxbytes=10MB
|
|
stdout_logfile_backups=3
|
|
|
|
[program:indicators_fetcher]
|
|
command=python indicators_fetcher.py --log-level normal
|
|
autostart=true
|
|
autorestart=true
|
|
stdout_logfile=/app/_logs/indicators_fetcher.log
|
|
stderr_logfile=/app/_logs/indicators_fetcher.log
|
|
stdout_logfile_maxbytes=10MB
|
|
stdout_logfile_backups=3
|
|
|
|
[program:cron_scheduler]
|
|
command=python scripts/cron_scheduler.py --log-level normal
|
|
autostart=true
|
|
autorestart=true
|
|
stdout_logfile=/app/_logs/cron_scheduler.log
|
|
stderr_logfile=/app/_logs/cron_scheduler.log
|
|
stdout_logfile_maxbytes=10MB
|
|
stdout_logfile_backups=3
|