No description
Find a file
nocci bde0f34a80
Some checks failed
build-and-push / docker (push) Failing after 0s
📝 docs(README): simplify and update documentation
- remove detailed setup instructions and history
- add quick-start guide for Docker and Docker Compose
- update CI and configuration sections
- streamline language and formatting for clarity
2025-12-29 14:36:18 +00:00
.forgejo/workflows 📦 build(ci): add build-and-push workflow for docker images 2025-12-29 14:31:25 +00:00
.github Merge branch 'dev' 2025-05-16 00:15:45 +02:00
.vscode vscode update changed config 2023-12-19 11:33:38 +01:00
src note on git describe for version 2025-05-13 23:43:29 +02:00
test enquirer: esc is fine, but after first prompt SIGINT will be ignore; onRawSIGINT keeps process running -> switch to inquirer 2025-05-14 00:30:39 +02:00
.dockerignore sort .dockerignore 2023-11-07 12:03:15 +01:00
.gitignore gitignore *.env for safety :) 2023-02-22 00:52:25 +01:00
aliexpress.js fix CodeQL alerts 5-7 2025-05-14 00:46:37 +02:00
CONTRIBUTING.md Allow forks to create builds and fix failing build 2023-10-27 11:37:32 +00:00
docker-compose.yml sample command: and environment: in docker-compose.yml, #85 2023-03-06 22:13:58 +01:00
docker-entrypoint.sh fix: docker-entrypoint.sh uses safe shebang 2024-09-28 18:34:39 +01:00
Dockerfile sonarcloud fixes 2023-11-07 15:20:58 +01:00
epic-games.js Current free game title in blue 2025-04-15 17:26:27 +02:00
eslint.config.js eslint: prefer-const 2024-03-07 13:47:58 +01:00
gog.js Current free game title in blue 2025-04-15 17:26:27 +02:00
jsconfig.json fix vscode problem in jsconfig with module vs. moduleResolution 2023-11-07 16:45:17 +01:00
LICENSE Create LICENSE - AGPL-3.0 2023-11-06 19:12:16 +01:00
package-lock.json ncu -u 2025-05-15 23:51:49 +02:00
package.json ncu -u 2025-05-15 23:51:49 +02:00
prime-gaming.js feat(auth): enhance automatic login and MFA handling 2025-12-29 14:15:22 +00:00
README.md 📝 docs(README): simplify and update documentation 2025-12-29 14:36:18 +00:00
sonar-project.properties Sonarqube support with ESLint 2023-09-26 19:12:09 +00:00
steam-games.js uncommited steam-games.js from 2024-09-24 - WIP just saves all games and their stats 2025-05-14 00:18:22 +02:00
unrealengine.js filenamify datetime recordHar for Windows : -> ., fix #336 2024-06-25 15:30:02 +02:00

Free Games Claimer (Fork)

Automates claiming of free games for:

  • Epic Games Store (and Epic-linked assets)
  • Amazon Prime Gaming / Luna claims (incl. external stores like GOG, Legacy, Microsoft)
  • GOG giveaways
  • Optional extras: Steam stats, AliExpress dailies (experimental)

This fork adds a Forgejo CI pipeline and instructions for running the pre-built image from your own registry.

Requirements

  • Docker or Podman (empfohlen) oder Node.js ≥ 20 zum lokalen Lauf
  • (Optional) Python apprise für Benachrichtigungen: pip install apprise
  • Für Playwright: Linux-Desktop-Abhängigkeiten sind im Container enthalten; lokal ggf. npm install zieht Firefox mit.

Schnellstart (Docker Run)

docker run --rm -it \
  -p 6080:6080 \
  -v fgc:/fgc/data \
  -e SHOW=1 \
  <REGISTRY_IMAGE>:latest \
  node prime-gaming.js
  • <REGISTRY_IMAGE> z. B. git.sky-net.it/nocci/free-games-claimer
  • Ports 6080/5900: noVNC/VNC (nur nötig mit SHOW=1)
  • Daten/Configs landen in Volume fgc unter /fgc/data

Docker Compose Beispiel

services:
  fgc:
    image: <REGISTRY_IMAGE>:latest
    container_name: fgc
    environment:
      - SHOW=1            # Browser sichtbar via VNC/noVNC
      # - PG_EMAIL=...
      # - PG_PASSWORD=...
      # - PG_OTPKEY=...
    volumes:
      - fgc:/fgc/data
    ports:
      - "6080:6080"       # noVNC
      # - "5900:5900"     # VNC optional
    command: bash -c "node epic-games; node prime-gaming; node gog"
volumes:
  fgc:

CI / eigenes Image

  • Workflow: .forgejo/workflows/build.yml baut/pusht auf push nach main.
  • Secrets in Forgejo setzen:
    • REGISTRY (z. B. git.sky-net.it)
    • REGISTRY_IMAGE (z. B. git.sky-net.it/nocci/free-games-claimer)
    • REG_USER, REG_TOKEN (PAT mit Paket-Push)
  • Self-hosted Runner mit Docker-Access (runs-on: self-hosted) wird benötigt.

Konfiguration (Umgebungsvariablen)

Typische Optionen:

  • SHOW=0/1 (0 = headless, 1 = UI)
  • WIDTH, HEIGHT (Browsergröße)
  • TIMEOUT, LOGIN_TIMEOUT (Sek.)
  • Login: EMAIL, PASSWORD global; spezifisch EG_EMAIL, EG_PASSWORD, EG_OTPKEY, PG_EMAIL, PG_PASSWORD, PG_OTPKEY, GOG_EMAIL, GOG_PASSWORD
  • Prime-Gaming: PG_REDEEM=1 (Keys automatisch einlösen, experimentell), PG_CLAIMDLC=1, PG_TIMELEFT=<Tage> zum Überspringen mit langer Restzeit
  • Screenshots: SCREENSHOTS_DIR (Standard data/screenshots)
  • Notifications: NOTIFY='...' (Apprise-URL), optional NOTIFY_TITLE

Du kannst eine data/config.env anlegen; sie wird per dotenv geladen und überschreibt nichts, was bereits in der Umgebung gesetzt ist.

Lokal ohne Docker

npm install
SHOW=0 PG_EMAIL=... PG_PASSWORD=... PG_OTPKEY=... node prime-gaming.js
  • Playwright lädt Firefox beim npm install in ~/.cache/ms-playwright.
  • Für sichtbaren Browser SHOW=1 (GUI/Xvfb nötig).

Persistenz & Ausgaben

  • Daten & Status: data/*.json (pro Store)
  • Browserprofil: data/browser
  • Screenshots: data/screenshots/<store>/
  • Optionale Videos/HAR: RECORD=1data/record/

Tipp: Bei Captchas oder Erst-Login SHOW=1 nutzen und einmal manuell einloggen; Cookies bleiben im Profil. Notifications via NOTIFY helfen bei Fehlermeldungen (z. B. Captcha, Login).***