Skip to content
This repository was archived by the owner on Nov 19, 2025. It is now read-only.
This repository was archived by the owner on Nov 19, 2025. It is now read-only.

ecs-cli compose service up giving error for --enable-service-discovery #1069

@shahbaz07

Description

@shahbaz07

Hi,

I am running below command to create service in Fargate and enable service discovery for it. It works fine and my service is discoverable in my VPC.

ecs-cli compose --project-name backend service up --private-dns-namespace tutorial --vpc vpc-04deee8176dce7d7d --enable-service-discovery

I have to run this command from my CD pipeline so if there is any change in service it will automatically deploy new version of service. But when I run this command again. It gives below error.

Service Discovery can not be enabled on an existing ECS Service

Please let me know how I can fix this issue. I saw in console there is option to choose existing service discovery for service. But I couldn't fine any option in ecs-cli compose service up documentation for this.

If you need any other information please let me know.

ecs-cli version 1.19.1 (a20cf74)
aws cli version: aws-cli/2.0.20 Python/3.7.3 Linux/4.4.0-1109-aws botocore/2.0.0dev24

Regards
Shahbaz Sajjad

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions