Ajout système de tâches et Fix: suggerer et signaler_bug
This commit is contained in:
parent
a49aa6717f
commit
f1c0921a58
7 changed files with 1434 additions and 5 deletions
|
|
@ -77,16 +77,16 @@ def run_mep_logic(author, commit_msg, branch="main"):
|
|||
except subprocess.CalledProcessError as e:
|
||||
send_discord_log("ERREUR MIGRATION", f"❌ Migration GitLab échouée: {e.stderr}", 15158332, author, commit_msg)
|
||||
|
||||
duration = (datetime.now() - start_time).total_seconds()
|
||||
msg = f"✅ **Déploiement réussi en {duration:.2f}s**\nLe bot est à jour et redémarré."
|
||||
send_discord_log("VALIDÉ", msg, 3066993, author, commit_msg)
|
||||
|
||||
# 3. PM2 (Appelé après le message pour éviter que le kill du serv ne bloque l'envoi)
|
||||
# 3. PM2 (Appelé avant le message de succès)
|
||||
subprocess.run(
|
||||
f"source /home/discord/.nvm/nvm.sh && pm2 restart {PROCESS_NAME}",
|
||||
shell=True, check=True, capture_output=True, executable="/bin/bash"
|
||||
)
|
||||
|
||||
duration = (datetime.now() - start_time).total_seconds()
|
||||
msg = f"✅ **Déploiement réussi en {duration:.2f}s**\nLe bot est à jour et redémarré."
|
||||
send_discord_log("VALIDÉ", msg, 3066993, author, commit_msg)
|
||||
|
||||
except Exception as e:
|
||||
error_msg = f"❌ **ERREUR de déploiement**\n```python\n{str(e)}\n```"
|
||||
send_discord_log("ÉCHEC", error_msg, 15158332, author, commit_msg)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue