1
0
mirror of https://github.com/Ylianst/MeshAgent synced 2025-12-15 15:53:55 +00:00

add wants and after

This commit is contained in:
Simon Smith
2022-06-26 14:24:06 +01:00
committed by GitHub
parent 36681dbbf8
commit 6f4bf643fc

View File

@@ -2723,7 +2723,10 @@ function serviceManager()
{
throw ('unknown location for systemd configuration files');
}
conf.write('[Unit]\nDescription=' + serviceDescription + '\n');
conf.write('[Unit]\n');
conf.write('Description=' + serviceDescription + '\n');
conf.write('Wants=network-online.target\n');
conf.write('After=network-online.target\n');
conf.write('[Service]\n');
conf.write('WorkingDirectory=' + options.installPath + '\n');
conf.write('ExecStart=' + options.installPath.split(' ').join('\\x20') + options.target.split(' ').join('\\x20') + ' ' + parameters + '\n');