Target only runs the necessary operations on the target. Let's say you have an s3 bucket that has had a code change, and you only want to update the s3 bucket, you'd use Target.
Replace will mark a resource for recreation, so delete + recreate
k
kind-spring-48153
07/30/2024, 8:07 AM
Then if I want to recreate only one of my resources, do I use
--target
parameter not
--replace
parameter? (if the code changed)
d
dry-keyboard-94795
07/30/2024, 8:07 AM
If it's already marked for recreation because of code changes, then yes.
Otherwise, use Replace
k
kind-spring-48153
07/30/2024, 8:10 AM
Finally, I understand two parameter's mechanism.
Thank you Anthony
No matter how you like to participate in developer communities, Pulumi wants to meet you there. If you want to meet other Pulumi users to share use-cases and best practices, contribute code or documentation, see us at an event, or just tell a story about something cool you did with Pulumi, you are part of our community.