mirror of
https://github.com/LightZirconite/Microsoft-Rewards-Bot.git
synced 2026-01-10 09:16:16 +00:00
Initial commit
This commit is contained in:
42
compose.yaml
Normal file
42
compose.yaml
Normal file
@@ -0,0 +1,42 @@
|
||||
services:
|
||||
microsoft-rewards-script:
|
||||
build: .
|
||||
container_name: microsoft-rewards-script
|
||||
restart: unless-stopped
|
||||
|
||||
# Volume mounts: Specify a location where you want to save the files on your local machine.
|
||||
volumes:
|
||||
- ./src/accounts.jsonc:/usr/src/microsoft-rewards-script/src/accounts.jsonc:ro
|
||||
- ./src/config.jsonc:/usr/src/microsoft-rewards-script/src/config.jsonc:ro
|
||||
- ./sessions:/usr/src/microsoft-rewards-script/sessions # Optional, saves your login session
|
||||
|
||||
environment:
|
||||
TZ: "America/Toronto" # Set your timezone for proper scheduling (used by image and scheduler)
|
||||
NODE_ENV: "production"
|
||||
# Force headless when running in Docker (uses Chromium Headless Shell only)
|
||||
FORCE_HEADLESS: "1"
|
||||
|
||||
# ============================================================
|
||||
# SCHEDULING MODE: Choose one
|
||||
# ============================================================
|
||||
# Option 1: Built-in JavaScript Scheduler (default, recommended)
|
||||
# - No additional setup needed
|
||||
# - Uses config.jsonc schedule settings
|
||||
# - Lighter resource usage
|
||||
#SCHEDULER_DAILY_JITTER_MINUTES_MIN: "2"
|
||||
#SCHEDULER_DAILY_JITTER_MINUTES_MAX: "10"
|
||||
#SCHEDULER_PASS_TIMEOUT_MINUTES: "180"
|
||||
#SCHEDULER_FORK_PER_PASS: "true"
|
||||
|
||||
# Option 2: Native Cron (for users who prefer traditional cron)
|
||||
# Uncomment these lines to enable cron instead:
|
||||
#USE_CRON: "true"
|
||||
#CRON_SCHEDULE: "0 9 * * *" # Daily at 9 AM (see https://crontab.guru)
|
||||
#RUN_ON_START: "true" # Run once immediately on container start
|
||||
|
||||
# Security hardening
|
||||
security_opt:
|
||||
- no-new-privileges:true
|
||||
|
||||
# Default: use built-in scheduler (entrypoint handles mode selection)
|
||||
command: ["npm", "run", "start:schedule"]
|
||||
Reference in New Issue
Block a user