Skip to content

Commit

Permalink
Remote Work
Browse files Browse the repository at this point in the history
  • Loading branch information
n0nuser committed Apr 7, 2022
1 parent ccde168 commit eb556c7
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions monitor_agent/core/helper.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,16 @@

def getLogger(level: str, filename: str):
log_level = ""
tranlation = {
translation = {
"debug": logging.DEBUG,
"info": logging.INFO,
"warning": logging.WARNING,
"error": logging.ERROR,
"critical": logging.CRITICAL,
}
try:
if level in tranlation.keys():
log_level = tranlation[level]
if level in translation.keys():
log_level = translation[level]
else:
logging.warning("Level not established in Settings.json")
log_level = logging.info
Expand Down
6 changes: 3 additions & 3 deletions monitor_agent/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
"url": "http://127.0.0.1:8000/api/alerts/"
},
"auth": {
"agent_token": "31dc98714ebef0f1feadae06efaee156ab9210fa",
"agent_token": "1b08ef6ec3af737bcc443050a3556638251abfe6",
"name": "localhost",
"user_token": "690b8d290d08fa26eecf3d69b6d2b76fee28b430"
"user_token": "609d79c47e1beb3ec0425ec2e3ad5bbea79994f4"
},
"endpoints": {
"agent_endpoint": "http://localhost:8000/api/agents/",
Expand All @@ -19,7 +19,7 @@
"enable_logfile": false,
"get_endpoint": true,
"log_filename": "metrics.json",
"post_interval": 10
"post_interval": 60
},
"thresholds": {
"cpu_percent": 50,
Expand Down

0 comments on commit eb556c7

Please sign in to comment.