mirror of
https://github.com/clusterio/clusterio.git
synced 2026-11-18 07:33:12 +09:00
Merge pull request #1200 from bbassie/feature/log-retention
Delete log files older than a configurable number of days
This commit is contained in:
1 parent
9ec817c1c6
commit
e37bf31cd3
6 files changed
+177
-1
No files matched your search
@@ -210,6 +210,11 @@ async function startHost() {
|
||||
// From this point on the host should run
|
||||
await hostConfigLock.acquire();
|
||||
|
||||
lib.startLogRetention(
|
||||
[path.join(args.logDirectory, "host")],
|
||||
() => hostConfig.get("host.log_retention_days"),
|
||||
);
|
||||
|
||||
// If we get here the command was run
|
||||
await fs.mkdir(hostConfig.get("host.instances_directory"), { recursive: true });
|
||||
await fs.mkdir(hostConfig.get("host.mods_directory"), { recursive: true });
|
||||
|
||||
Reference in new issue
Block a user