Swap user and cid position for service file naming
- allows better globbing for manual intervention if required
This commit is contained in:
parent
b29d97d28a
commit
6c52ab58b5
|
@ -11,7 +11,7 @@ runner = str(Path(BASEPATH, "markattendance.py"))
|
|||
|
||||
def Schedule(time, user, cid, day, capture_output=True):
|
||||
command = [sys.executable, runner, user, cid, str(day)]
|
||||
servicename = "att_{}_{}".format(user, cid)
|
||||
servicename = "att_{}_{}".format(cid, user)
|
||||
|
||||
restartIntervalMinutes = 1
|
||||
# restartAttemptCount = 5
|
||||
|
@ -35,7 +35,7 @@ def Schedule(time, user, cid, day, capture_output=True):
|
|||
sch = subprocess.run( schedulecmd, capture_output=capture_output)
|
||||
return sch
|
||||
def cancelSchedule(user, cid, capture_output=True):
|
||||
servicename = "att_{}_{}.timer".format(user, cid)
|
||||
servicename = "att_{}_{}.timer".format(cid, user)
|
||||
|
||||
schedulecmd = ['systemctl',
|
||||
'--user',
|
||||
|
|
Loading…
Reference in New Issue