test_rollback_on_failure_cleans_up

✓ pass on Combined (All three PRs merged) · 46.4 s

--rollback-on-failure: the install fails, then Helm deletes what it applied and leaves no release.

Same test on other tiers: PR1 ✓ passPR2 ✓ passPR3 — n/a

Requirements

R11 A readiness failure or timeout fails the install; --rollback-on-failure rolls back implemented

Installs: [...] If any of the readiness checks fail or timeout, the entire install would fail and the release marked as failed. If --atomic, or its SDK equivalent is used, a rollback to the last successful install would take place.HIP-0025, Sequencing order

Note: Helm v4 renamed --atomic to --rollback-on-failure.

The test needs these tier features: ordered, subcharts.

What the test observed

The test asserts on these facts. Times come from the kube-apiserver audit log (UTC).

install

exit 1: context deadline exceeded

apiserver timeline

18:44:08.536  apply  Deployment/broken
18:44:53.548  delete Deployment/broken

releases left in namespace

(none)

Charts

The charts that the helm commands below read. This run did not keep chart archives, so the links go to the chart directories in the harness commit.

Commands

Every command that the test ran, in order, with the start time, the exit code and the output. The paths are relative to the root of the repository.

18:44:08.390 $ kubectl --context kind-hip0025-e2e delete namespace e2e-combined-rollback-on-failure-cleans-up --ignore-not-found --wait=true --timeout=120s
[exit 0, 0.0s]


18:44:08.424 $ kubectl --context kind-hip0025-e2e create namespace e2e-combined-rollback-on-failure-cleans-up
[exit 0, 0.0s]
namespace/e2e-combined-rollback-on-failure-cleans-up created


18:44:08.455 $ .bin/helm-combined install r charts/hip-lifecycle-failure --namespace e2e-combined-rollback-on-failure-cleans-up --wait=ordered --timeout 45s --rollback-on-failure --kube-context kind-hip0025-e2e
[exit 1, 45.2s]
Error: INSTALLATION FAILED: release r failed, and has been uninstalled due to rollback-on-failure being set: resource Deployment/e2e-combined-rollback-on-failure-cleans-up/broken not ready. status: InProgress, message: Available: 0/1
context deadline exceeded


18:44:54.661 $ .bin/helm-combined list --deployed --failed --pending --superseded --uninstalled --short --namespace e2e-combined-rollback-on-failure-cleans-up --kube-context kind-hip0025-e2e
[exit 0, 0.0s]


18:44:54.698 $ kubectl --context kind-hip0025-e2e get Deployment broken -n e2e-combined-rollback-on-failure-cleans-up
[exit 1, 0.0s]
Error from server (NotFound): deployments.apps "broken" not found


18:44:54.737 $ kubectl --context kind-hip0025-e2e get Deployment dependent -n e2e-combined-rollback-on-failure-cleans-up
[exit 1, 0.0s]
Error from server (NotFound): deployments.apps "dependent" not found


18:44:54.772 $ kubectl --context kind-hip0025-e2e get secret -n e2e-combined-rollback-on-failure-cleans-up -l owner=helm,name=r -o json
[exit 0, 0.0s]
{
    "apiVersion": "v1",
    "items": [],
    "kind": "List",
    "metadata": {
        "resourceVersion": ""
    }
}


18:44:54.812 $ kubectl --context kind-hip0025-e2e delete namespace e2e-combined-rollback-on-failure-cleans-up --wait=false
[exit 0, 0.0s]
namespace "e2e-combined-rollback-on-failure-cleans-up" deleted


Files

FileSizeContent
audit.jsonl 63.5 KB 18 kube-apiserver audit records for the namespace of the test
commands.log 1.9 KB the commands above
observations.json 312 B the observations above, as JSON