[Feature Request]: Add support for `--force` flag for `svc package`
Describe your idea/feature/enhancement
I wish I could force a new deployment for services that are configured with image.location: foo:latest, such that when I am deploying through AWS CodePipeline, these services would be re-deployed with the latest images.
My specific use case is one where I have multiple services which are deployed from the same image. Instead of re-building this image for each service, I wish to have only one service manifest that builds and uploads the image to ECR, and the other services reference the latest image in the same repository.
I have been able to configure this setup correctly, except the services using image.location: foo:latest are never actually deployed as the generated templates are the not changed.
Proposal
Add support for --force for svc package, similar to how --force is supported for env package.
Additional Details
Please let me know if there are other ways to achieve my goal of avoiding to build one copy of the same image for each service.
Hi @ezet! Your use case makes sense to me. I wonder if you could achieve this by adding stages.test_commands to your pipeline manifest and just add commands that call copilot svc deploy --force for each of the services that are configured with image.location: foo:latest?
@dannyrandall I finally got around to try this, and it seems to work fine 👍 Thank you for the tip!