add logs
This commit is contained in:
parent
d47cd4f0b9
commit
8883487425
1 changed files with 6 additions and 1 deletions
7
index.js
7
index.js
|
|
@ -179,12 +179,17 @@ async function restoreCache(cacheConfig) {
|
|||
}
|
||||
|
||||
async function startRemoteCacheServer() {
|
||||
core.startGroup("Remote cache server")
|
||||
|
||||
core.debug(`Remote cache server log file path: ${config.remoteCacheServer.logPath}`)
|
||||
const log = fs.openSync(config.remoteCacheServer.logPath, 'a')
|
||||
const serverProcess = fork(path.join(__dirname, 'dist', 'remote-cache-server', 'index.js'), [], {
|
||||
detached: true,
|
||||
stdio: ['ignore', log, log, 'ipc']
|
||||
})
|
||||
serverProcess.unref()
|
||||
|
||||
|
||||
core.info(`Started remote cache server (${serverProcess.pid}`)
|
||||
core.saveState('remote-cache-server-pid', serverProcess.pid.toString())
|
||||
core.endGroup()
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue