-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from Garage-ISEP/dev
Dev
- Loading branch information
Showing
8 changed files
with
90 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
.github | ||
.env | ||
.gitignore | ||
docker-compose.yml | ||
Dockerfile | ||
README.md |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +0,0 @@ | ||
.dockerignore | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,39 @@ | ||
# GarageDiscordBot | ||
|
||
Un bot Discord pour le serveur Garage, créé par Simon Tuloup - promo 2027. | ||
|
||
- Attribution automatique des rôles | ||
- Génération d'OTP pour le local NDL | ||
- Informations sur le propriétaire du serveur | ||
|
||
## Commandes | ||
|
||
`/add_member <pseudo> <lab>` : peut être exécuté par les présidents ou VP de lab pour ajouter des membres à leur lab. | ||
|
||
`/remove_member <pseudo> <lab>` : peut être exécuté par les présidents ou VP de lab pour retirer des membres de leur lab. | ||
|
||
Fonctionnement: Les membres possédant un rôle nommé "Prez - X" ou "VicePrez - X" peuvent ajouter ou retirer le rôle "X" à un autre membre en utilisant les commandes `/add_member` et `/remove_member`. Les admins aussi. | ||
|
||
|
||
`/code_ndl` : nécessite le rôle `code`, permet de générer un code valable 1h pour le local NDL. | ||
|
||
`/owner` : affiche les informations sur le propriétaire du serveur. | ||
|
||
`/ping` : affiche le ping du bot. | ||
|
||
`&&getlog` : nécessite le rôle `admin`, affiche les logs de `/code_ndl`. | ||
|
||
`&&purge` : nécessite le rôle `admin`, force la purge des OTP périmés de `/code_ndl`. Renvoie un booléen indiquant si des codes ont été supprimés ou non. | ||
|
||
## Fonctionnalités supplémentaires | ||
|
||
- Fait tourner les fichiers de log pour éviter de dépasser 20MB, archive les anciens fichiers de log sous la forme `CodeLog-Archive-{date}.bak`. | ||
|
||
|
||
## Installation | ||
|
||
1. Téléchargez le fichier `docker-compose.yml` et le fichier `.env`. | ||
2. Remplissez le fichier `.env` avec les informations nécessaires. | ||
3. Exécutez la commande `docker compose up -d` pour lancer le bot. | ||
|
||
Lien vers le dépôt GitHub : <https://github.com/Garage-ISEP/GarageDiscordBot> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,15 @@ | ||
DISCORD_GARAGEBOT_TOKEN="" | ||
DISCORD_ROLE_MEMBRE_ID = | ||
|
||
NUKI_API_TOKEN = "" | ||
SMARTLOCK_ID = | ||
|
||
|
||
############# SETTINGS ############ | ||
|
||
# in minutes | ||
OTP_DURATION = 60 | ||
|
||
# in Seconds | ||
PURGE_FREQ = 3600 | ||
DISCORD_GARAGEBOT_TOKEN="" | ||
DISCORD_ROLE_MEMBRE_ID = | ||
DISCORD_ROLE_ADMIN_ID = | ||
|
||
NUKI_API_TOKEN = "" | ||
SMARTLOCK_ID = | ||
|
||
|
||
############# SETTINGS ############ | ||
|
||
# in minutes | ||
OTP_DURATION = 60 | ||
|
||
# in Seconds | ||
PURGE_FREQ = 3600 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
version: "3" | ||
services: | ||
GarageDiscordBot: | ||
image: ghcr.io/garage-isep/garagediscordbot:latest | ||
container_name: GarageDiscordBot | ||
restart: always | ||
env_file: | ||
- .env | ||
volumes: | ||
- ./log:/bot/log |
File renamed without changes.