mirror of
https://github.com/dkmstr/openuds.git
synced 2025-01-05 09:17:54 +03:00
Logs for debugging
This commit is contained in:
parent
098620cd05
commit
e835c018b4
@ -92,8 +92,10 @@ class CommonService(object):
|
|||||||
import stat
|
import stat
|
||||||
|
|
||||||
if os.path.isfile(cmd):
|
if os.path.isfile(cmd):
|
||||||
|
logger.debug('File "{}" was found!!'.format(cmd))
|
||||||
if (os.stat(cmd).st_mode & stat.S_IXUSR) != 0:
|
if (os.stat(cmd).st_mode & stat.S_IXUSR) != 0:
|
||||||
subprocess.call([cmd, ])
|
res = subprocess.call([cmd, ])
|
||||||
|
logger.debug('Result of executing cmd was {}'.format(res))
|
||||||
return True
|
return True
|
||||||
else:
|
else:
|
||||||
logger.info('{} file exists but it it is not executable (needs execution permission by admin/root)'.format(section))
|
logger.info('{} file exists but it it is not executable (needs execution permission by admin/root)'.format(section))
|
||||||
@ -158,6 +160,7 @@ class CommonService(object):
|
|||||||
# Now try to run the "runonce" element
|
# Now try to run the "runonce" element
|
||||||
runOnce = store.runApplication()
|
runOnce = store.runApplication()
|
||||||
if runOnce is not None:
|
if runOnce is not None:
|
||||||
|
logger.debug('Executing {}'.format(runOnce))
|
||||||
if self.execute(runOnce, 'RunOnce') is True:
|
if self.execute(runOnce, 'RunOnce') is True:
|
||||||
# operations.reboot()
|
# operations.reboot()
|
||||||
return False
|
return False
|
||||||
|
Loading…
Reference in New Issue
Block a user