전달 파이프라인에서 관리할 새 출시 버전을 만들기 위해 Cloud Deploy를 호출할 때 파이프라인 및 대상은 해당 출시 버전에 대해 현재 상태로 보존됩니다. 전달 파이프라인 및 대상 정의 파일을 계속 수정할 수 있지만 이러한 변경사항은 이후 출시 버전에만 영향을 줍니다.
Cloud Deploy에서 이 작업을 수행하는 이유는 무엇인가요?
출시 버전의 신뢰성 및 내구성을 유지하기 위해 전달 파이프라인 및 연관된 해당 리소스는 출시 버전이 생성될 때 보존됩니다. 이러한 보존에 따라 전달 파이프라인 정의가 최근에 변경되더라도 생성된 매니페스트가 이를 수용할 수 없도록 출시 버전에 영향을 주지 않습니다.
이 작업이 왜 중요한가요?
출시 버전이 생성된 후 전달 파이프라인이 변경될 경우 Cloud Deploy는 새 정의가 아닌 출시 버전이 생성되었을 때의 이전 파이프라인 정의에 따라 출시 버전을 배포합니다. 사용자 또는 조직의 다른 사람이 출시 버전이 업데이트된 파이프라인 동작을 따를 것이라고 기대하지 않는 한 이 동작은 문제가 되지 않습니다.
이 작업이 중요한 경우는 언제인가요?
release를 승격하는 경우
출시 버전이 처음 생성될 때 Cloud Deploy는 파이프라인의 스냅샷을 생성합니다. 이 스냅샷(파이프라인 인스턴스)은 release의 배포 주기를 제어하는 파이프라인 버전입니다.
누군가 파이프라인을 수정한 후, 사용자가 출시 버전을 다음 대상으로 승격할 경우, Cloud Deploy는 배포가 예상한 대로 동작하지 않을 수 있음을 알리는 경고를 표시합니다. 여기에 대해서는 승격을 확인하거나 취소하는 방식으로 응답할 수 있습니다.
gcloud deploy releases promote
…
WARNING: The delivery pipeline was modified since was created.
This release will promote based on the state of the delivery pipeline at the
time of release creation.
It will not be rolled out to the pipeline in its current state.
Promoting will result in .
Learn more at: https://cloud.google.com/deploy/docs/pipeline-instances
Are you sure you want to promote to ? Y/n
작업을 계속하도록 선택하면 출시 버전이 의도된 대상 클러스터로 승격되고 대상은 release를 만들 때 정의된 대로 구성됩니다. 즉, 대상 변경사항이 release에 영향을 주지 않습니다.
rollout을 승인하는 경우
승격의 경우와 마찬가지로, rollout을 승인하고 출시 버전과 연관된 파이프라인 인스턴스와 현재 파이프라인 정의 사이에 불일치가 있으면 Cloud Deploy가 이러한 불일치를 알리는 메시지를 표시합니다. 이에 대해서는 승인을 확인하거나 취소할 수 있습니다.
release를 롤백하는 경우
전달 파이프라인 또는 대상이 rollout 다음에 변경되고 롤백을 시도하면 파이프라인 불일치가 발생합니다. Cloud Deploy는 정말 롤백할지 확인하는 메시지를 표시합니다. 이 경우 롤백하기 전 전달 파이프라인 또는 대상의 변경사항을 조사하는 것이 좋습니다.
[[["이해하기 쉬움","easyToUnderstand","thumb-up"],["문제가 해결됨","solvedMyProblem","thumb-up"],["기타","otherUp","thumb-up"]],[["이해하기 어려움","hardToUnderstand","thumb-down"],["잘못된 정보 또는 샘플 코드","incorrectInformationOrSampleCode","thumb-down"],["필요한 정보/샘플이 없음","missingTheInformationSamplesINeed","thumb-down"],["번역 문제","translationIssue","thumb-down"],["기타","otherDown","thumb-down"]],["최종 업데이트: 2025-04-03(UTC)"],[[["\u003cp\u003eCloud Deploy preserves the delivery pipeline and target configurations at the time a release is created to ensure reliability and prevent unintended consequences from subsequent changes.\u003c/p\u003e\n"],["\u003cp\u003eChanges to the delivery pipeline or target definitions after a release is created will only affect future releases, not the existing one.\u003c/p\u003e\n"],["\u003cp\u003eWhen promoting, approving, or rolling back a release, Cloud Deploy checks for mismatches between the stored pipeline instance and the current pipeline definition, warning the user if discrepancies exist.\u003c/p\u003e\n"],["\u003cp\u003eIf there is a mismatch, the user will be prompted to confirm or cancel the action to either proceed or stop.\u003c/p\u003e\n"]]],[],null,["# Pipeline instances per release\n\nWhen you invoke Cloud Deploy to create a new release to be managed by your\ndelivery pipeline, the pipeline and targets are preserved in their current state\nfor that release. You can still edit your delivery pipeline and target\ndefinition files, but the changes that you make affect future releases only.\n| **Note:** In addition to storing the pipeline instance with the release, Cloud Deploy also stores the execution environment, as [defined with the target](/deploy/docs/config-files#target_definitions).\n\nWhy does Cloud Deploy do this?\n------------------------------\n\nTo keep your releases reliable and durable, the delivery pipeline and its\nassociated resources are preserved at the time the release is created. This\npreservation prevents recent changes to the delivery pipeline definition from\naffecting the release in ways the generated manifests might not be able to\naccommodate.\n\nWhy does this matter?\n---------------------\n\nWhen a delivery pipeline is changed after your release is created,\nCloud Deploy delivers the release according to the previous pipeline definition (as it was when the release was created) not the new definition. This\nbehavior isn't a problem unless you, or someone else in your organization,\nexpects the release to follow the updated pipeline behavior.\n\nWhen does this matter?\n----------------------\n\n- When you promote a `release`\n\n When the release was first created, Cloud Deploy took a snapshot\n of the pipeline. That snapshot---the *pipeline instance* ---is the\n version of the pipeline that controls the deployment cycle of that `release`.\n\n If anyone *does* edit the pipeline, and then you promote the release to the\n next target, Cloud Deploy displays a warning informing you that\n the deployment might not behave as you expect. You can respond by confirming\n the promotion or canceling it.\n\n```\n gcloud deploy releases promote \n ...\nThe pipeline or targets were cached when the release was created, but the source\nhas changed since then. You should review the differences before proceeding.\n\nPromoting release xxxx-release-00n to target xxx.\n\nDo you want to continue (Y/n)?\n\n```\n\nIf you confirm that you want to continue, then the release is promoted to\nthe intended target cluster, with that target configured as defined when you\ncreated the `release`. That is, changes to the target do not affect that\n`release`.\n\n- When you approve a `rollout`\n\n As with promotion, if you approve a `rollout` and there's a mismatch between\n the pipeline instance associated with the release, and the current pipeline\n definition, Cloud Deploy displays a message telling you about the\n mismatch. You can confirm or cancel the approval.\n- When you roll back a `release`.\n\n If a delivery pipeline or target is changed after a `rollout`, and you try to\n roll back, there will be a pipeline mismatch. Cloud Deploy will\n prompt you to confirm you really want to roll back. In this case, we strongly\n recommend you examine the change to the delivery pipeline or target before\n rolling back.\n\nWhat you can do\n---------------\n\nIf you change a delivery pipeline, or any of its targets, after a release is\ncreated, you can do the following:\n\n- Let the original pipeline continue executing, without any of the changes from\n the edited pipeline.\n\n The changes in the pipeline don't affect the rest of the release.\n- Create a new release.\n\n The new release uses the new, edited delivery pipeline, and starts again with\n the first target in your delivery pipeline progression."]]