From 9fd8f2dbd0bf1edd05eaf94d6a067f5709cfb573 Mon Sep 17 00:00:00 2001 From: Alvaro Neira Ayuso Date: Thu, 2 Jan 2020 20:47:17 +0100 Subject: Add schedule command No action executed. This command only return a 200 OK message. --- src/ogRest.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/ogRest.py b/src/ogRest.py index 0e05ad8..ddedf16 100644 --- a/src/ogRest.py +++ b/src/ogRest.py @@ -88,6 +88,8 @@ class ogRest(): self.process_shellout(client) elif ("hardware" in URI): self.process_hardware(client) + elif ("run/schedule" in URI): + self.process_schedule(client) else: client.send(self.getResponse(ogResponses.BAD_REQUEST)) elif ("POST" in op): @@ -157,3 +159,6 @@ class ogRest(): path = '/tmp/Chrd-' + client.ip threading.Thread(target=ogThread.prochardware, args=(self.msgqueue, path,)).start() client.send(self.getResponse(ogResponses.OK)) + + def process_schedule(self, client): + client.send(self.getResponse(ogResponses.OK)) -- cgit v1.2.3-18-g5258