Don't wait to stop services

This commit is contained in:
root 2022-01-30 16:25:10 +01:00
parent e0098cfdf4
commit fc3ff1ef18

View file

@ -39,7 +39,9 @@ if __name__ == '__main__':
parser.add_argument('STATE', type=State, choices=list(State)) parser.add_argument('STATE', type=State, choices=list(State))
parser.add_argument('PRIORITY', type=int) parser.add_argument('PRIORITY', type=int)
args = parser.parse_args() args = parser.parse_args()
time.sleep(2)
if args.STATE == State.MASTER:
time.sleep(2)
with open(os.path.join(path, "keepalived.json")) as config_file: with open(os.path.join(path, "keepalived.json")) as config_file:
config = json.load(config_file) config = json.load(config_file)