fixes
parent
4664914de6
commit
96ca464c8a
|
|
@ -874,12 +874,6 @@ class CloudRunnerOptions {
|
||||||
static get skipCache() {
|
static get skipCache() {
|
||||||
return CloudRunnerOptions.getInput(`skipCache`) === `true` || false;
|
return CloudRunnerOptions.getInput(`skipCache`) === `true` || false;
|
||||||
}
|
}
|
||||||
static get watchCloudRunnerToEnd() {
|
|
||||||
if (CloudRunnerOptions.asyncCloudRunner) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
return CloudRunnerOptions.getInput(`watchToEnd`) || true;
|
|
||||||
}
|
|
||||||
static get asyncCloudRunner() {
|
static get asyncCloudRunner() {
|
||||||
return (CloudRunnerOptions.getInput('asyncCloudRunner') || `false`) === `true` || false;
|
return (CloudRunnerOptions.getInput('asyncCloudRunner') || `false`) === `true` || false;
|
||||||
}
|
}
|
||||||
|
|
@ -1414,7 +1408,7 @@ class AWSJobStack {
|
||||||
taskDefCloudFormation = taskDefCloudFormation.replace(`ContainerMemory:
|
taskDefCloudFormation = taskDefCloudFormation.replace(`ContainerMemory:
|
||||||
Default: 2048`, `ContainerMemory:
|
Default: 2048`, `ContainerMemory:
|
||||||
Default: ${Number.parseInt(memory)}`);
|
Default: ${Number.parseInt(memory)}`);
|
||||||
if (cloud_runner_options_1.default.watchCloudRunnerToEnd) {
|
if (!cloud_runner_options_1.default.asyncCloudRunner) {
|
||||||
taskDefCloudFormation = aws_cloud_formation_templates_1.AWSCloudFormationTemplates.insertAtTemplate(taskDefCloudFormation, '# template resources logstream', task_definition_formation_1.TaskDefinitionFormation.streamLogs);
|
taskDefCloudFormation = aws_cloud_formation_templates_1.AWSCloudFormationTemplates.insertAtTemplate(taskDefCloudFormation, '# template resources logstream', task_definition_formation_1.TaskDefinitionFormation.streamLogs);
|
||||||
}
|
}
|
||||||
for (const secret of secrets) {
|
for (const secret of secrets) {
|
||||||
|
|
@ -1631,8 +1625,8 @@ class AWSTaskRunner {
|
||||||
const taskArn = task.tasks?.[0].taskArn || '';
|
const taskArn = task.tasks?.[0].taskArn || '';
|
||||||
cloud_runner_logger_1.default.log('Cloud runner job is starting');
|
cloud_runner_logger_1.default.log('Cloud runner job is starting');
|
||||||
await AWSTaskRunner.waitUntilTaskRunning(taskArn, cluster);
|
await AWSTaskRunner.waitUntilTaskRunning(taskArn, cluster);
|
||||||
cloud_runner_logger_1.default.log(`Cloud runner job status is running ${(await AWSTaskRunner.describeTasks(cluster, taskArn))?.lastStatus} Watch:${cloud_runner_options_1.default.watchCloudRunnerToEnd} Async:${cloud_runner_options_1.default.asyncCloudRunner}`);
|
cloud_runner_logger_1.default.log(`Cloud runner job status is running ${(await AWSTaskRunner.describeTasks(cluster, taskArn))?.lastStatus} Async:${cloud_runner_options_1.default.asyncCloudRunner}`);
|
||||||
if (!cloud_runner_options_1.default.watchCloudRunnerToEnd) {
|
if (cloud_runner_options_1.default.asyncCloudRunner) {
|
||||||
const shouldCleanup = false;
|
const shouldCleanup = false;
|
||||||
const output = '';
|
const output = '';
|
||||||
cloud_runner_logger_1.default.log(`Watch Cloud Runner To End: false`);
|
cloud_runner_logger_1.default.log(`Watch Cloud Runner To End: false`);
|
||||||
|
|
|
||||||
File diff suppressed because one or more lines are too long
|
|
@ -257,14 +257,6 @@ class CloudRunnerOptions {
|
||||||
return CloudRunnerOptions.getInput(`skipCache`) === `true` || false;
|
return CloudRunnerOptions.getInput(`skipCache`) === `true` || false;
|
||||||
}
|
}
|
||||||
|
|
||||||
static get watchCloudRunnerToEnd(): boolean {
|
|
||||||
if (CloudRunnerOptions.asyncCloudRunner) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return CloudRunnerOptions.getInput(`watchToEnd`) || true;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static get asyncCloudRunner(): boolean {
|
public static get asyncCloudRunner(): boolean {
|
||||||
return (CloudRunnerOptions.getInput('asyncCloudRunner') || `false`) === `true` || false;
|
return (CloudRunnerOptions.getInput('asyncCloudRunner') || `false`) === `true` || false;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -41,7 +41,7 @@ export class AWSJobStack {
|
||||||
`ContainerMemory:
|
`ContainerMemory:
|
||||||
Default: ${Number.parseInt(memory)}`,
|
Default: ${Number.parseInt(memory)}`,
|
||||||
);
|
);
|
||||||
if (CloudRunnerOptions.watchCloudRunnerToEnd) {
|
if (!CloudRunnerOptions.asyncCloudRunner) {
|
||||||
taskDefCloudFormation = AWSCloudFormationTemplates.insertAtTemplate(
|
taskDefCloudFormation = AWSCloudFormationTemplates.insertAtTemplate(
|
||||||
taskDefCloudFormation,
|
taskDefCloudFormation,
|
||||||
'# template resources logstream',
|
'# template resources logstream',
|
||||||
|
|
|
||||||
|
|
@ -65,11 +65,11 @@ class AWSTaskRunner {
|
||||||
CloudRunnerLogger.log('Cloud runner job is starting');
|
CloudRunnerLogger.log('Cloud runner job is starting');
|
||||||
await AWSTaskRunner.waitUntilTaskRunning(taskArn, cluster);
|
await AWSTaskRunner.waitUntilTaskRunning(taskArn, cluster);
|
||||||
CloudRunnerLogger.log(
|
CloudRunnerLogger.log(
|
||||||
`Cloud runner job status is running ${(await AWSTaskRunner.describeTasks(cluster, taskArn))?.lastStatus} Watch:${
|
`Cloud runner job status is running ${(await AWSTaskRunner.describeTasks(cluster, taskArn))?.lastStatus} Async:${
|
||||||
CloudRunnerOptions.watchCloudRunnerToEnd
|
CloudRunnerOptions.asyncCloudRunner
|
||||||
} Async:${CloudRunnerOptions.asyncCloudRunner}`,
|
}`,
|
||||||
);
|
);
|
||||||
if (!CloudRunnerOptions.watchCloudRunnerToEnd) {
|
if (CloudRunnerOptions.asyncCloudRunner) {
|
||||||
const shouldCleanup: boolean = false;
|
const shouldCleanup: boolean = false;
|
||||||
const output: string = '';
|
const output: string = '';
|
||||||
CloudRunnerLogger.log(`Watch Cloud Runner To End: false`);
|
CloudRunnerLogger.log(`Watch Cloud Runner To End: false`);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue