(shellServer: ShellServer, location: string, content: string)
| 437 | } |
| 438 | |
| 439 | async function updateMarkerFile(shellServer: ShellServer, location: string, content: string) { |
| 440 | try { |
| 441 | await shellServer.exec(`mkdir -p '${path.posix.dirname(location)}' && CONTENT="$(cat '${location}' 2>/dev/null || echo ENOENT)" && [ "\${CONTENT:-${content}}" != '${content}' ] && echo '${content}' > '${location}'`); |
| 442 | return true; |
| 443 | } catch (err) { |
| 444 | return false; |
| 445 | } |
| 446 | } |
| 447 | |
| 448 | async function runPostAttachCommand(params: ResolverParameters, lifecycleCommandOriginMap: LifecycleHooksInstallMap, containerProperties: ContainerProperties, remoteEnv: Promise<Record<string, string>>, secrets: Promise<Record<string, string>>) { |
| 449 | await runLifecycleCommands(params, lifecycleCommandOriginMap, containerProperties, 'postAttachCommand', remoteEnv, secrets, true); |
no test coverage detected