diff --git a/run.py b/run.py new file mode 100644 index 0000000..603a0f8 --- /dev/null +++ b/run.py @@ -0,0 +1,67 @@ +#!/usr/bin/env python3 +# -*- coding: utf-8 -*- +## Utilisez la commande 'python3 -m pip install cowsay' pour ajouter ce MOTD. +## Sinon, supprimez cette partie du programme jusqu'au prochain commentaire +import socket +import cowsay + +## Editez le fichier config.py pour y mettre les bonnes variables. +#cowsay.ghostbusters("SSH-Notifier \n The owner has been notified of this login") + +## importation des dependances +import re +import sys +from config import config +sys.path.insert(1, config["plateform_directory"]) +from telegram import telegram_send_message +from discord import discord_send_message +import os +import subprocess +import json +import requests +#Pattern pour reconnaitre une IP +ip_pattern = "(?:^|\b(?' : + print("Mauvaise réponse de l'api") + return "Echec de la recuperation du lieu" + data = localisation + return data.json() + +if __name__ == '__main__': + main() +