mirror of https://github.com/calzoneman/sync.git
set uid timeout
Allow the timeout to be changed allowing more time before dropping root privledges
This commit is contained in:
parent
960f94bfb6
commit
ca0f0c4086
|
@ -198,3 +198,5 @@ setuid:
|
||||||
enabled: false
|
enabled: false
|
||||||
group: 'users'
|
group: 'users'
|
||||||
user: 'user'
|
user: 'user'
|
||||||
|
# how long to wait in ms before changing uid/gid
|
||||||
|
timeout: 15
|
||||||
|
|
|
@ -103,7 +103,8 @@ var defaults = {
|
||||||
setuid: {
|
setuid: {
|
||||||
enabled: false,
|
enabled: false,
|
||||||
"group": "users",
|
"group": "users",
|
||||||
"user": "nobody"
|
"user": "nobody",
|
||||||
|
"timeout": 15
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -11,5 +11,5 @@ if (Config.get("setuid.enabled")) {
|
||||||
console.log('Cowardly refusing to keep the process alive as root.');
|
console.log('Cowardly refusing to keep the process alive as root.');
|
||||||
process.exit(1);
|
process.exit(1);
|
||||||
}
|
}
|
||||||
}, 15);
|
}, (Config.get("setuid.timeout")));
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue