baked in cloud formation template
parent
d26cc2b620
commit
2e971d93a4
|
|
@ -1055,8 +1055,10 @@ class AWSJobStack {
|
|||
let taskDefCloudFormation = aws_cloud_formation_templates_1.AWSCloudFormationTemplates.readTaskCloudFormationTemplate();
|
||||
const cpu = cloud_runner_1.default.buildParameters.cloudRunnerCpu || '1024';
|
||||
const memory = cloud_runner_1.default.buildParameters.cloudRunnerMemory || '2048';
|
||||
taskDefCloudFormation = taskDefCloudFormation.replace('1024', cpu);
|
||||
taskDefCloudFormation = taskDefCloudFormation.replace('2048', memory);
|
||||
taskDefCloudFormation = taskDefCloudFormation.replace(`ContainerCpu:
|
||||
Default: 1024`, cpu);
|
||||
taskDefCloudFormation = taskDefCloudFormation.replace(`ContainerMemory:
|
||||
Default: 2048`, memory);
|
||||
for (const secret of secrets) {
|
||||
secret.ParameterKey = `${buildGuid.replace(/[^\dA-Za-z]/g, '')}${secret.ParameterKey.replace(/[^\dA-Za-z]/g, '')}`;
|
||||
if (typeof secret.ParameterValue == 'number') {
|
||||
|
|
@ -1836,12 +1838,12 @@ Parameters:
|
|||
Default: 80
|
||||
Description: What port number the application inside the docker container is binding to
|
||||
ContainerCpu:
|
||||
Type: Number
|
||||
Default: 1024
|
||||
Type: Number
|
||||
Description: How much CPU to give the container. 1024 is 1 CPU
|
||||
ContainerMemory:
|
||||
Type: Number
|
||||
Default: 2048
|
||||
Type: Number
|
||||
Description: How much memory in megabytes to give the container
|
||||
BUILDGUID:
|
||||
Type: String
|
||||
|
|
|
|||
File diff suppressed because one or more lines are too long
|
|
@ -26,8 +26,16 @@ export class AWSJobStack {
|
|||
let taskDefCloudFormation = AWSCloudFormationTemplates.readTaskCloudFormationTemplate();
|
||||
const cpu = CloudRunner.buildParameters.cloudRunnerCpu || '1024';
|
||||
const memory = CloudRunner.buildParameters.cloudRunnerMemory || '2048';
|
||||
taskDefCloudFormation = taskDefCloudFormation.replace('1024', cpu);
|
||||
taskDefCloudFormation = taskDefCloudFormation.replace('2048', memory);
|
||||
taskDefCloudFormation = taskDefCloudFormation.replace(
|
||||
`ContainerCpu:
|
||||
Default: 1024`,
|
||||
cpu,
|
||||
);
|
||||
taskDefCloudFormation = taskDefCloudFormation.replace(
|
||||
`ContainerMemory:
|
||||
Default: 2048`,
|
||||
memory,
|
||||
);
|
||||
for (const secret of secrets) {
|
||||
secret.ParameterKey = `${buildGuid.replace(/[^\dA-Za-z]/g, '')}${secret.ParameterKey.replace(
|
||||
/[^\dA-Za-z]/g,
|
||||
|
|
|
|||
|
|
@ -24,12 +24,12 @@ Parameters:
|
|||
Default: 80
|
||||
Description: What port number the application inside the docker container is binding to
|
||||
ContainerCpu:
|
||||
Type: Number
|
||||
Default: 1024
|
||||
Type: Number
|
||||
Description: How much CPU to give the container. 1024 is 1 CPU
|
||||
ContainerMemory:
|
||||
Type: Number
|
||||
Default: 2048
|
||||
Type: Number
|
||||
Description: How much memory in megabytes to give the container
|
||||
BUILDGUID:
|
||||
Type: String
|
||||
|
|
|
|||
Loading…
Reference in New Issue