Skip to content

Commit

Permalink
Merge pull request #1408 from aligent/feature/Optionally-Disable-Exec
Browse files Browse the repository at this point in the history
FEAT: Add prop to disable ECS exec
  • Loading branch information
AdamJHall authored Nov 22, 2024
2 parents 1d292fd + 5d7154e commit 7ff2635
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
8 changes: 7 additions & 1 deletion packages/graphql-mesh-server/lib/fargate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -232,6 +232,12 @@ export interface MeshServiceProps {
* }
*/
cpuStepScalingOptions?: Partial<BasicStepScalingPolicyProps>;

/**
* Enable ECS Exec on the fargate containers
* @default true
*/
enableEcsExec?: boolean;
}

export class MeshService extends Construct {
Expand Down Expand Up @@ -412,7 +418,7 @@ export class MeshService extends Construct {
serviceName:
props.serviceName !== undefined ? props.serviceName : undefined,
certificate,
enableExecuteCommand: true,
enableExecuteCommand: props.enableEcsExec ?? true,
cpu: props.cpu || 512, // 0.5 vCPU
memoryLimitMiB: props.memory || 1024, // 1 GB
taskDefinition: taskDefinition,
Expand Down
6 changes: 6 additions & 0 deletions packages/graphql-mesh-server/lib/graphql-mesh-server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -226,6 +226,12 @@ export type MeshHostingProps = {
* @default - AWS Generated name
*/
dashboardName?: string;

/**
* Enable ECS Exec on the fargate containers
* @default true
*/
enableEcsExec?: boolean;
};

export class MeshHosting extends Construct {
Expand Down

0 comments on commit 7ff2635

Please sign in to comment.