mirror of
https://github.com/MikroWizard/mikroman.git
synced 2025-07-07 12:34:30 +02:00
fix adding router if router peer connection is tunnel
This commit is contained in:
parent
60c4f1870f
commit
1fe9637f50
2 changed files with 7 additions and 3 deletions
|
@ -5,6 +5,7 @@
|
|||
# MikroWizard.com , Mikrotik router management solution
|
||||
# Author: sepehr.ha@gmail.com
|
||||
|
||||
from logging.config import IDENTIFIER
|
||||
import pytz
|
||||
import datetime
|
||||
import time
|
||||
|
@ -705,7 +706,10 @@ def backup_router(dev):
|
|||
def store_config(dev,configs):
|
||||
dir=config.BACKUP_DIR
|
||||
#add device mac and curent date to dir
|
||||
dir=dir+dev.mac+"/"+datetime.datetime.now().strftime("%Y-%m-%d")+"/"
|
||||
identifier=dev.mac
|
||||
if identifier=='tunnel':
|
||||
identifier=identifier+"_devid_"+(str(dev.id))
|
||||
dir=dir+identifier+"/"+datetime.datetime.now().strftime("%Y-%m-%d")+"/"
|
||||
filename=datetime.datetime.now().strftime("%H-%M-%S")+".txt"
|
||||
filedir=dir+filename
|
||||
try:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue