mirror of
https://github.com/LightZirconite/Microsoft-Rewards-Bot.git
synced 2026-01-08 00:26:16 +00:00
fix: Update Docker configuration to improve volume mounts and remove unnecessary Playwright browser copy
This commit is contained in:
@@ -41,9 +41,8 @@ docs/
|
||||
.gitlab-ci.yml
|
||||
|
||||
# Session and runtime data (mounted as volumes)
|
||||
sessions/
|
||||
# Note: sessions/ NOT excluded - needed for volume mount in Docker
|
||||
reports/
|
||||
browser/
|
||||
|
||||
# Development files
|
||||
*.log
|
||||
|
||||
@@ -79,10 +79,6 @@ COPY --from=builder /usr/src/microsoft-rewards-bot/dist ./dist
|
||||
COPY --from=builder /usr/src/microsoft-rewards-bot/package*.json ./
|
||||
COPY --from=builder /usr/src/microsoft-rewards-bot/node_modules ./node_modules
|
||||
|
||||
# FIXED: Copy Playwright browsers from builder (they're in node_modules with PLAYWRIGHT_BROWSERS_PATH=0)
|
||||
# This prevents "Chromium not installed" errors on subsequent runs
|
||||
COPY --from=builder /usr/src/microsoft-rewards-bot/node_modules/@playwright ./node_modules/@playwright
|
||||
|
||||
# Copy runtime scripts with proper permissions and normalize line endings for non-Unix users
|
||||
# IMPROVED: Scripts now organized in docker/ folder
|
||||
COPY --chmod=755 docker/run_daily.sh ./docker/run_daily.sh
|
||||
|
||||
@@ -8,9 +8,9 @@ services:
|
||||
|
||||
# Volume mounts: Specify a location where you want to save the files on your local machine.
|
||||
volumes:
|
||||
- ./src/accounts.jsonc:/usr/src/microsoft-rewards-bot/dist/accounts.jsonc:ro
|
||||
- ./src/config.jsonc:/usr/src/microsoft-rewards-bot/dist/config.jsonc:ro
|
||||
- ./sessions:/usr/src/microsoft-rewards-bot/dist/browser/sessions # Optional, saves your login session
|
||||
- ../src/accounts.jsonc:/usr/src/microsoft-rewards-bot/dist/accounts.jsonc:ro
|
||||
- ../src/config.jsonc:/usr/src/microsoft-rewards-bot/dist/config.jsonc:ro
|
||||
- ../sessions:/usr/src/microsoft-rewards-bot/sessions # Optional, saves your login session
|
||||
|
||||
environment:
|
||||
TZ: "America/Toronto" # Set your timezone for proper scheduling
|
||||
|
||||
Reference in New Issue
Block a user