Epirank is a program that retrieves all students and their GPAs from EPITECH and makes them available by web & JSON.
The first time you will start the server, it will update the datase and then will update it every day around 3am.
The webservice runs using :
- Gin framework and listen on the port
8080
. - Go-sqlite3 as a SQLite driver.
- Logrus for logging.
There is only one route :
GET /
: It can take some parameters in the query.
Parameter | Description | Optional |
---|---|---|
city | The city we want (STG, ...). If parameter is not present we ask for every city. | โ |
promotion | The promotion we want (tek1, tek2, ...) | โ |
format | We can ask JSON. If not present, returns the HTML ranking page | โ |
{
"login": "email",
"password": "password"
}
If you want to delete the configuration file after the launch, set the environment variable :
If you are using Fish shell:
set -gx EPIRANK_DELETE_CREDENTIALS true
go build
./Epirank
docker build -t epirank .
TODO
- The database which is storing all students data is in
/tmp
. The authentication file too. - EPIRANK_DELETE_CREDENTIALS : if set at true, deletes the authentication file
- GIN_MODE [debug/release]
docker run -d --name epirank
-v "~/epirank_data":/tmp
-e EPIRANK_DELETE_CREDENTIALS=true
-e GIN_MODE=release
epirank