Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(ecs): CloudMapNamespaceOptions should allow bringing your own namespace resource #26698

Open
1 of 2 tasks
vaietc opened this issue Aug 10, 2023 · 3 comments
Open
1 of 2 tasks
Labels
@aws-cdk/aws-ecs Related to Amazon Elastic Container effort/medium Medium work item – several days of effort feature-request A feature should be added or improved. p1

Comments

@vaietc
Copy link

vaietc commented Aug 10, 2023

Describe the feature

The ECS CDK simplifies setting up default namespaces for Service Connect and Service Discovery via the use of CloudMapNamespaceOptions which automatically creates the Cloud Map namespaces. We'd like to extend this to support existing namespaces that may have been created outside of ECS Cluster configuration.

Use Case

We have found customer use cases where they already have an existing namespace modeled outside of CloudMapNamespaceOptions that they'd now like to use as the default for Service Connect but the current constructs don't allow this.

Proposed Solution

A previous bug fixed for Service Connect also recommend a potential path forward by modeling a cloudMapNamespace resource in the CloudMapNamespaceOptions which would be a workable solution

Other Information

No response

Acknowledgements

  • I may be able to implement this feature request
  • This feature might incur a breaking change

CDK version used

2.84.0

Environment details (OS name and version, etc.)

Mac OS 13.4

@vaietc vaietc added feature-request A feature should be added or improved. needs-triage This issue or PR still needs to be triaged. labels Aug 10, 2023
@github-actions github-actions bot added the @aws-cdk/aws-ecs Related to Amazon Elastic Container label Aug 10, 2023
@peterwoodworth peterwoodworth added p1 effort/medium Medium work item – several days of effort and removed needs-triage This issue or PR still needs to be triaged. labels Aug 10, 2023
@peterwoodworth
Copy link
Contributor

Thanks for opening a feature request for this 👍🏻

@chrishiestand
Copy link

Something like this would be nice:

const namespace = new PrivateDnsNamespace(
    this,
    'my-cloudmap-namespace',
    {
        name: 'my.tld',
        vpc: myVpc,
    }
);

const ecsCluster = new Cluster(this, 'my-ecs-cluster', {
    clusterName: 'myCluster',
    vpc: myVpc,
    enableFargateCapacityProviders: true,
    defaultCloudMapNamespace: namespace,
});

@MatthewAitken
Copy link

One really problematic case this would solve is when following the AWS Organizations best-practice of having a Network account provision the vpcs. In that case, the private zone has to be associated with the vpc in question before it can be used by the ECS cluster.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
@aws-cdk/aws-ecs Related to Amazon Elastic Container effort/medium Medium work item – several days of effort feature-request A feature should be added or improved. p1
Projects
None yet
Development

No branches or pull requests

4 participants