Python win32serviceutil.RestartService() Examples

The following are 5 code examples of win32serviceutil.RestartService(). You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may also want to check out all available functions/classes of the module win32serviceutil , or try the search function .
Example #1
Source File: win32.py    From opsbro with MIT License 6 votes vote down vote up
def signal_child(service, command):
    if command == 'stop':
        win32serviceutil.StopService(service)
    elif command == 'restart':
        win32serviceutil.RestartService(service)
    else:
        win32serviceutil.ControlService(service, control_codes[command]) 
Example #2
Source File: win32.py    From cherrypy with BSD 3-Clause "New" or "Revised" License 5 votes vote down vote up
def signal_child(service, command):
    if command == 'stop':
        win32serviceutil.StopService(service)
    elif command == 'restart':
        win32serviceutil.RestartService(service)
    else:
        win32serviceutil.ControlService(service, control_codes[command]) 
Example #3
Source File: win32.py    From bazarr with GNU General Public License v3.0 5 votes vote down vote up
def signal_child(service, command):
    if command == 'stop':
        win32serviceutil.StopService(service)
    elif command == 'restart':
        win32serviceutil.RestartService(service)
    else:
        win32serviceutil.ControlService(service, control_codes[command]) 
Example #4
Source File: win32.py    From Tautulli with GNU General Public License v3.0 5 votes vote down vote up
def signal_child(service, command):
    if command == 'stop':
        win32serviceutil.StopService(service)
    elif command == 'restart':
        win32serviceutil.RestartService(service)
    else:
        win32serviceutil.ControlService(service, control_codes[command]) 
Example #5
Source File: win32.py    From moviegrabber with GNU General Public License v3.0 5 votes vote down vote up
def signal_child(service, command):
    if command == 'stop':
        win32serviceutil.StopService(service)
    elif command == 'restart':
        win32serviceutil.RestartService(service)
    else:
        win32serviceutil.ControlService(service, control_codes[command])