Last active
October 9, 2017 20:26
-
-
Save pvgomes/c680de4e69955d4f6597ad57607d83cb to your computer and use it in GitHub Desktop.
restartPy
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import time | |
quantity = int(input("Quantity to restart: ")) | |
while(quantity > 0): | |
print("Runnint restart %s" % (str(quantity))) | |
time.sleep(3) | |
os.system("initctl restart worker"); | |
quantity = quantity - 1 | |
print("Finish") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment