Deploy --sync deploys twice
# 🌱|help-and-getting-started
s
Hi all, I noticed that
deploy <app> --sync
deployes a first version without the
garden-sync-init
and once it is successfully running then it deploys again, this time with
garden-sync-init
container. Is this expected? I am using a Deploy action type Helm.
f
Hi @swift-island-27000 , yes this is the intended behavior for helm actions since we need to modify a resource that is deployed as part of a helm release. Pre-rendering the helm chart and adding the garden-sync-init container as an init container to the helm chart is not always reliable. E.g. based on the values provided to a chart a different resource might be deployed in the end like a statefulset or a deployment. Even though we have the values and can resolve all templating beforehand, we leave what to deploy to the helm install command and we are not applying the resulting manifests directly. The behavior you describe was therefore the most reliable way to insert the initContainer required for sync mode.
s
make sense! thanks!
2 Views