This repository has been archived on 2022-09-04. You can view files and clone it, but cannot push or open issues or pull requests.
Go to file
2020-11-18 12:54:19 +01:00
cron change a naming convention, add 'master' server to special servers, updateServerDataWorker fallbacks to not gzipped file 2020-11-18 12:53:32 +01:00
.gitignore create a new instance of http.Client with timeout 2020-11-18 12:49:20 +01:00
dev.sh fetch server config/unit_config/building_config 2020-06-19 17:42:38 +02:00
Dockerfile update Dockerfile 2020-11-18 12:53:32 +01:00
go.mod add LICENSE and README.md, cron now inserts all versions and all special servers into the database 2020-11-18 12:53:32 +01:00
go.sum add LICENSE and README.md, cron now inserts all versions and all special servers into the database 2020-11-18 12:53:32 +01:00
LICENSE add LICENSE, update DOCKERFILE 2020-11-18 12:53:32 +01:00
main.go remove allservers cache 2020-11-18 12:53:32 +01:00
readme.md add readme.md 2020-11-18 12:53:32 +01:00
README.md update README.md 2020-11-18 12:54:19 +01:00

tribalwarshelp.com cron

Features:

  • Adds automatically new TribalWars servers.
  • Fetches TribalWars servers data (players, tribes, ODA, ODD, ODS, OD, conquers, configs).
  • Saves daily player/tribe stats, player/tribe history, tribe changes, player name changes, server stats.
  • Vacuums the database daily from old player/tribe stats, player/tribe history.

Development

Required env variables to run this cron (you can set them directly in your system or create .env.development file):

DB_USER=your_db_user
DB_NAME=your_db_name
DB_PORT=5432
DB_HOST=your_db_host
DB_PASSWORD=your_db_pass

Prerequisites

  1. Golang
  2. PostgreSQL database

Installing

  1. Clone this repo.
  2. Navigate to the directory where you have cloned this repo.
  3. Set the required env variables directly in your system or create .env.development file.
  4. go run main.go