mirror of
https://gitlab.sectorq.eu/jaydee/mqtt_srv.git
synced 2025-12-14 10:34:53 +01:00
bitwarden
This commit is contained in:
11
mqtt_srv.cfg
11
mqtt_srv.cfg
@@ -1,2 +1,9 @@
|
|||||||
[global]
|
[global]
|
||||||
mykey = prod/v1/install/
|
mykey = prod/v1/install/
|
||||||
|
|
||||||
|
[morefine]
|
||||||
|
right = ["HDMI-A-0", "1920x1080"]
|
||||||
|
tleft = ["DisplayPort-6", "1920x1080"]
|
||||||
|
tright = ["DisplayPort-8", "1920x1080"]
|
||||||
|
left = ["DisplayPort-7", "2560x1440"]
|
||||||
|
mid = ["DisplayPort-0", "3440x1440"]
|
||||||
@@ -17,17 +17,18 @@ import ctypes
|
|||||||
import getopt
|
import getopt
|
||||||
import random
|
import random
|
||||||
import requests
|
import requests
|
||||||
from backports import configparser
|
import configparser
|
||||||
|
|
||||||
config = configparser.ConfigParser()
|
config = configparser.ConfigParser()
|
||||||
config.read(r'mqtt_srv.cfg')
|
config.read(r'/etc/mqtt_srv/mqtt_srv.cfg')
|
||||||
|
|
||||||
print(config.get('global', 'mykey') )
|
print(config.get('morefine', 'right') )
|
||||||
|
|
||||||
|
|
||||||
#import psutil
|
#import psutil
|
||||||
stats = {}
|
stats = {}
|
||||||
VERSION = "1.0.33"
|
VERSION = "1.0.33"
|
||||||
|
|
||||||
curos = platform.system()
|
curos = platform.system()
|
||||||
host = platform.node().lower()
|
host = platform.node().lower()
|
||||||
print(host)
|
print(host)
|
||||||
@@ -75,6 +76,7 @@ def uptime():
|
|||||||
|
|
||||||
def writeLog(msg, svr="INFO"):
|
def writeLog(msg, svr="INFO"):
|
||||||
ts = datetime.datetime.now().strftime("%Y-%m-%d %H:%M:%S")
|
ts = datetime.datetime.now().strftime("%Y-%m-%d %H:%M:%S")
|
||||||
|
|
||||||
if curos == "Windows":
|
if curos == "Windows":
|
||||||
log_path = "c:\Program Files\jaydee\jaydee.log"
|
log_path = "c:\Program Files\jaydee\jaydee.log"
|
||||||
else:
|
else:
|
||||||
|
|||||||
Reference in New Issue
Block a user