- Introduce app/ package with config, services (storage, notifications), API server, and crawler modules - Add BaseCrawler and BarronsCrawler; extract notifications and storage - Keep enhanced_crawler.py as back-compat entry delegating to app.runner - Add template crawler for future sites - Update README with new structure and usage - Extend .env.template with DATA_DIR/LOG_DIR options
26 lines
745 B
Plaintext
26 lines
745 B
Plaintext
# 基本設定
|
||
CHECK_INTERVAL=300
|
||
LOG_LEVEL=INFO
|
||
ALWAYS_NOTIFY_ON_STARTUP=false
|
||
|
||
# 電子郵件通知設定(Gmail 範例)
|
||
EMAIL_SMTP_SERVER=smtp.gmail.com
|
||
EMAIL_SMTP_PORT=587
|
||
# 可選: starttls | ssl | none
|
||
EMAIL_SMTP_SECURITY=starttls
|
||
EMAIL_FROM=your_email@gmail.com
|
||
EMAIL_TO=notification@gmail.com
|
||
EMAIL_USERNAME=your_email@gmail.com
|
||
EMAIL_PASSWORD=your_app_specific_password
|
||
|
||
# Slack Webhook(可選)
|
||
WEBHOOK_URL=https://hooks.slack.com/services/YOUR/SLACK/WEBHOOK
|
||
|
||
# Discord Webhook(可選)
|
||
DISCORD_WEBHOOK=https://discord.com/api/webhooks/YOUR/DISCORD/WEBHOOK
|
||
|
||
# 進階(可選):自訂資料與日誌目錄
|
||
# 預設 Docker 會使用 /app/data、/app/logs;本機則使用 ./data、./logs
|
||
# DATA_DIR=./data
|
||
# LOG_DIR=./logs
|