Documentation
¶
Overview ¶
Package phases declares the acceptance phases the Go harness carries.
hack/e2e-kind.sh stands the cluster up and runs every phase through run_recorded_phase. A phase ported to Go is one test function in the binary the driver builds from test/e2e, and this package is the contract between the two: the name the driver and support/e2e-suites.json know the phase by, the test that is the phase, the environment the driver hands it, the scenarios it records in the timing ledger, and the bound it runs under.
Three programs read it. The harness loads a phase's inputs from nothing else. hack/verify-kubernetes-support.go holds the driver's call to exactly those inputs. hack/acceptancecoverage lists the scenarios. The inputs are one struct per phase, so a phase reads what it declared and the compiler refuses anything else; a shell phase needed a hand-written environment contract and a scan of its source for the same answer.
The package imports nothing heavier than reflect, because the verifier and the coverage table import it too.
Index ¶
Constants ¶
This section is empty.
Variables ¶
var Alerting = define[AlertingInputs](Phase{ Name: "alerting", Test: "TestAlerting", Timeout: 90 * time.Minute, RequiresFull: []string{"assert"}, Scenarios: []string{ "native-producers", "monitoring-path", "unresolved-view-read-failures", "lost-scrape-target", "lost-view", "upgrade-alerts", }, })
Alerting proves scrape and admission faults, lost managers, and interrupted upgrades. Storage uses the certificate phase's independent monitoring setup.
var AlertingCertificates = define[AlertingInputs](Phase{ Name: "alerting-certificates", Test: "TestAlertingCertificates", Timeout: 60 * time.Minute, RequiresFull: []string{"assert"}, Scenarios: []string{"native-producers", "monitoring-path", "plan-store-large", "certificate-expiry"}, })
AlertingCertificates proves storage and expiry notifications and recovery. Both incidents share its monitoring namespace and native producers; each completes before the next changes certificates or retained plans.
var AlertingOperations = define[AlertingInputs](Phase{ Name: "alerting-operations", Test: "TestAlertingOperations", Timeout: 90 * time.Minute, Scenarios: []string{ "native-producers", "monitoring-path", "unresolved-apply", "ordinary-policy-waits", "stalled-operation", "resource-overdue", "lock-release-owed", "operations-failing", }, })
AlertingOperations owns operation incidents and the full no-page windows. It runs on another cluster so infrastructure faults cannot change its history.
var CertRotation = define[CertRotationInputs](Phase{ Name: "cert-rotation", Test: "TestCertRotation", Timeout: 100 * time.Minute, RequiresFull: []string{"assert"}, Scenarios: []string{ "recovery-guard", "live-helm-lookup", "corrupt-ca-recovery", "missing-secret-recreation", }, })
CertRotation proves certificate rotation: the exact recovery guard, Helm's live lookup, recovery from a corrupt CA and recreation of a deleted Secret.
var ControlPlane = define[ControlPlaneInputs](Phase{ Name: "assert", Test: "TestControlPlaneContract", Timeout: 60 * time.Minute, Scenarios: []string{ "manager-readiness", "crd-discovery", "finalizer-authorization", "realm-authorization", "plan-chunk-authorization", "webhook-configuration", "secret-isolation", "namespace-local-references", "verification-policy", "pod-webhook-outage-scope", "duration-bounds", "reference-keys", "managed-scope-selectors", "unsupported-engine", "suspended-schema-fixture", "approval-binding", "cross-namespace-approval", }, })
ControlPlane proves the control-plane contract: the release's readiness, discovery, authorization and admission shape, the API server's refusals, and the approval binding, against fixtures the later phases reuse.
var DataPlane = define[DataPlaneInputs](Phase{ Name: "dataplane", Test: "TestDataPlane", Timeout: 90 * time.Minute, RequiresFull: []string{"assert"}, Scenarios: []string{ "databases-and-fixtures", "postgresql-lifecycle", "native-plan-size-boundary", "closing-audits", "four-eyes-distinct-approver", "pod-metadata-admission", }, Preparation: 1, })
DataPlane proves the PostgreSQL lifecycle, both engines' size limits, four-eyes approval, and Pod metadata. It also prepares the other suites.
var HA = define[HAInputs](Phase{ Name: "ha", Test: "TestHA", Timeout: 45 * time.Minute, Scenarios: []string{ "lease-authorization", "leader-failover", "operation-after-failover", }, })
HA proves leader election across two manager replicas: one namespaced Lease with exact RBAC, a failover that keeps the Lease and moves its holder, and an operation the new leader admits and reports in its metrics.
var MigrationRuntimeMySQL = define[MigrationsInputs](Phase{ Name: "migration-runtime-mysql", Test: "TestMigrationRuntimeMySQL", Timeout: 45 * time.Minute, Scenarios: []string{ "runtime-artifact", "approval-resource-replacement", "approval-policy-change", "approval-transaction-mode-change", "approval-artifact-change", "approval-verification-policy-uid-change", "approval-verification-policy-content-change", "approval-executor-image-change", "approval-ptah-version-change", "unsupported-controller-state-after-approval", "unsupported-runner-protocol-after-approval", "running-apply-executor-image-change", }, })
MigrationRuntimeMySQL proves execution bindings and runtime refusals against its own native artifact and isolated databases.
var MigrationRuntimePostgreSQL = define[MigrationsInputs](Phase{ Name: "migration-runtime-postgresql", Test: "TestMigrationRuntimePostgreSQL", Timeout: 45 * time.Minute, Scenarios: []string{ "runtime-artifact", "approval-resource-replacement", "approval-policy-change", "approval-transaction-mode-change", "approval-artifact-change", "approval-verification-policy-uid-change", "approval-verification-policy-content-change", "approval-executor-image-change", "approval-ptah-version-change", "unsupported-controller-state-after-approval", "unsupported-runner-protocol-after-approval", "running-apply-executor-image-change", }, })
MigrationRuntimePostgreSQL proves execution bindings and runtime refusals against its own native artifact and isolated databases.
var MigrationsMySQL = define[MigrationsInputs](Phase{ Name: "migrations-mysql", Test: "TestMigrationsMySQL", Timeout: 150 * time.Minute, Scenarios: []string{ "migration-policy", "mysql-transaction-mode", "mysql-migrations", }, IsolatesNode: true, })
MigrationsMySQL proves the same path against MySQL, after the row that says which transaction mode a MySQL sequence may name.
var MigrationsPostgreSQL = define[MigrationsInputs](Phase{ Name: "migrations-postgresql", Test: "TestMigrationsPostgreSQL", Timeout: 150 * time.Minute, Scenarios: []string{ "migration-policy", "postgresql-migrations", }, IsolatesNode: true, })
MigrationsPostgreSQL proves the versioned-migration path against PostgreSQL: the approval gate, the applied sequence, the history it leaves, and every refusal and fault the path owes a person.
var ReferenceDataMySQL = define[ReferenceDataInputs](Phase{ Name: "reference-data-mysql", Test: "TestReferenceDataMySQL", Timeout: 60 * time.Minute, Scenarios: []string{ "declared-row-values", "mysql-reference-data", }, })
ReferenceDataMySQL proves the same on MySQL.
var ReferenceDataPostgreSQL = define[ReferenceDataInputs](Phase{ Name: "reference-data-postgresql", Test: "TestReferenceDataPostgreSQL", Timeout: 60 * time.Minute, Scenarios: []string{ "declared-row-values", "postgresql-reference-data", }, })
ReferenceDataPostgreSQL proves declared reference data on PostgreSQL, from a database with no tables: the first rows, a data-only change, a stale approval after an external edit, a withdrawn and an emptied declaration, a protected table, and no row value anywhere but the database.
var SchemaApprovals = define[DataPlaneInputs](Phase{ Name: "schema-approvals", Test: "TestSchemaApprovals", Timeout: 90 * time.Minute, RequiresFull: []string{"assert"}, Scenarios: []string{ "watches", "approval-resource-replacement", "approval-target-secret-change", "approval-destructive-policy-change", "approval-exclusion-policy-change", "approval-verification-policy-change", "approval-history-audit", "approval-executor-image-change", "approval-ptah-version-change", "unsupported-controller-state-after-approval", "unsupported-runner-protocol-after-approval", "running-apply-executor-image-change", }, })
SchemaApprovals proves independent approval and executor changes on both engines, without waiting for the unrelated interruption sequence.
var SchemaFaults = define[DataPlaneInputs](Phase{ Name: "schema-faults", Test: "TestSchemaFaults", Timeout: 160 * time.Minute, IsolatesNode: true, RequiresFull: []string{"assert"}, Scenarios: []string{ "external-postgresql-lifecycle", "mysql-lifecycle", "mysql-dsn-refusal", "watches", "mysql-drift-before-dispatch", "hung-schema-result-read", "job-deadline", "manager-restart", "runner-termination", "job-deletion", "closing-audits", }, })
SchemaFaults keeps the shared fault watches and cluster-wide barriers in one phase, including the lifecycle assertions that must hold after faults.
var Uninstall = define[UninstallInputs](Phase{ Name: "uninstall", Test: "TestUninstall", Timeout: 150 * time.Minute, Scenarios: []string{ "next-release-upgrade", "rollback", "uninstall", "reinstall-over-retained-crds", "exported-chart-install", }, })
Uninstall proves the release transitions after the upgrade: a synthetic next release that recovers from a late failure without interrupting a running Apply, a rollback refused over future state and then allowed, and an uninstall that removes the runtime and keeps the CRDs and live objects, followed by a reinstall over drifted CRDs and a fresh install of the exact exported chart bytes.
var Upgrade = define[UpgradeInputs](Phase{ Name: "upgrade", Test: "TestUpgrade", Timeout: 120 * time.Minute, Scenarios: []string{ "read-only-job-cleanup", "crd-preflight-refusals", "drifted-crd-upgrade", "controller-write-guard", "runtime-recovery", "singleton-coordination", }, })
Upgrade proves the CRD upgrade path: a CRD preflight that refuses a missing CRD, a newer schema or state and an incomplete or colliding identity without changing anything, drifted CRDs converged before the manager rolls out with every live object preserved, the manager's write guards, and one release per namespace.
Functions ¶
func Load ¶
Load reads the phase's inputs through lookup, which is os.LookupEnv outside a test. Every input is required and has to be non-empty: the driver binds each one, and a phase started without one would measure some other cluster or none. The error names every input that is missing, not only the first.
Types ¶
type AlertingInputs ¶
type AlertingInputs struct {
// Kubeconfig names the cluster the driver stood up.
Kubeconfig string `env:"E2E_KUBECONFIG"`
// OperatorNamespace is the release namespace.
OperatorNamespace string `env:"E2E_OPERATOR_NAMESPACE"`
// TestNamespace holds the existing approval used for a dry-run admission probe.
TestNamespace string `env:"E2E_TEST_NAMESPACE"`
// ExecutorImage publishes the native producer artifacts.
ExecutorImage string `env:"E2E_EXECUTOR_IMAGE"`
// RegistryService is the prepared in-cluster artifact registry.
RegistryService string `env:"E2E_REGISTRY_SERVICE"`
// HelmRelease is the installed release, whose values the rules are
// rendered with.
HelmRelease string `env:"E2E_HELM_RELEASE"`
// ChartPackage is the chart the release was installed from.
ChartPackage string `env:"E2E_CHART_PACKAGE"`
// The existing synthetic next release gives upgrade faults a distinct runtime.
NextChartPackage string `env:"E2E_NEXT_CHART_PACKAGE"`
NextValuesFile string `env:"E2E_NEXT_VALUES_FILE"`
// FixtureImage carries the alert receiver.
FixtureImage string `env:"E2E_FIXTURE_IMAGE"`
// PrometheusImage and AlertmanagerImage are the monitoring path, mirrored
// into the registry and pinned by digest.
PrometheusImage string `env:"E2E_PROMETHEUS_IMAGE"`
AlertmanagerImage string `env:"E2E_ALERTMANAGER_IMAGE"`
// RegistryCredentialsFile holds the registry's username and password,
// which the monitoring Pods pull their images with.
RegistryCredentialsFile string `env:"E2E_REGISTRY_CREDENTIALS_FILE"`
}
AlertingInputs is what the driver hands the alerting phase. The data-plane preparation supplies databases and a registry; alerting creates its own producers.
type CertRotationInputs ¶
type CertRotationInputs struct {
// Kubeconfig names the cluster the driver stood up.
Kubeconfig string `env:"E2E_KUBECONFIG"`
// OperatorNamespace is the release namespace, where the manager, the
// rotator, their Secrets and the webhook Service live.
OperatorNamespace string `env:"E2E_OPERATOR_NAMESPACE"`
// TestNamespace holds the approval the control-plane contract leaves
// behind. The phase reaches approval admission through it.
TestNamespace string `env:"E2E_TEST_NAMESPACE"`
// HelmRelease is the installed release.
HelmRelease string `env:"E2E_HELM_RELEASE"`
// ChartPackage is the packaged chart the release was installed from. The
// phase upgrades to it so that the chart's live lookup of the certificate
// runs against a cluster that has one.
ChartPackage string `env:"E2E_CHART_PACKAGE"`
}
CertRotationInputs is what the driver hands the certificate rotation phase.
type ControlPlaneInputs ¶
type ControlPlaneInputs struct {
// Kubeconfig names the cluster the driver stood up.
Kubeconfig string `env:"E2E_KUBECONFIG"`
// OperatorNamespace is the release namespace.
OperatorNamespace string `env:"E2E_OPERATOR_NAMESPACE"`
// TestNamespace is where the phase creates its schema, plan and approval
// fixtures, which the certificates and data-plane phases go on to use.
TestNamespace string `env:"E2E_TEST_NAMESPACE"`
// ForeignNamespace holds the objects a reference from TestNamespace must
// not reach.
ForeignNamespace string `env:"E2E_FOREIGN_NAMESPACE"`
// HelmRelease is the installed release.
HelmRelease string `env:"E2E_HELM_RELEASE"`
// ExecutorImage is the digest-pinned Ptah executor the release runs.
ExecutorImage string `env:"E2E_EXECUTOR_IMAGE"`
// RunnerImage is the runner image built beside the manager.
RunnerImage string `env:"E2E_RUNNER_IMAGE"`
// PtahVersion is the Ptah version bound beside the executor.
PtahVersion string `env:"E2E_PTAH_VERSION"`
// ControllerImage is the candidate manager image, pinned by digest.
ControllerImage string `env:"E2E_CONTROLLER_IMAGE"`
// ControllerRevision is the commit the candidate was built from.
ControllerRevision string `env:"E2E_CONTROLLER_REVISION"`
// ControllerStateVersion is the controller-state version the chart was
// stamped with.
ControllerStateVersion string `env:"E2E_CONTROLLER_STATE_VERSION"`
}
ControlPlaneInputs is what the driver hands the control-plane contract phase, which the driver knows as assert.
type DataPlaneInputs ¶
type DataPlaneInputs struct {
// Kubeconfig names the cluster the driver stood up.
Kubeconfig string `env:"E2E_KUBECONFIG"`
// OperatorNamespace is the release namespace.
OperatorNamespace string `env:"E2E_OPERATOR_NAMESPACE"`
// TestNamespace is where the phase stands up its registry endpoint, its
// databases and its fixtures, and where the migration suites find them.
TestNamespace string `env:"E2E_TEST_NAMESPACE"`
// HelmRelease is the installed release.
HelmRelease string `env:"E2E_HELM_RELEASE"`
// ChartPackage is the packaged chart the release was installed from. The
// four-eyes row upgrades the release to it with one value changed.
ChartPackage string `env:"E2E_CHART_PACKAGE"`
// PtahVersion is the Ptah version bound beside the executor.
PtahVersion string `env:"E2E_PTAH_VERSION"`
// ExecutorImage is the digest-pinned Ptah executor the release runs.
ExecutorImage string `env:"E2E_EXECUTOR_IMAGE"`
// RunnerImage is the runner image built beside the manager.
RunnerImage string `env:"E2E_RUNNER_IMAGE"`
// FixtureImage carries the TLS registry proxy and the fault fixtures.
FixtureImage string `env:"E2E_FIXTURE_IMAGE"`
// ControllerImage is the candidate manager image, pinned by digest.
ControllerImage string `env:"E2E_CONTROLLER_IMAGE"`
// ControllerRevision is the commit the candidate was built from.
ControllerRevision string `env:"E2E_CONTROLLER_REVISION"`
// ControllerStateVersion is the controller-state version the chart was
// stamped with.
ControllerStateVersion string `env:"E2E_CONTROLLER_STATE_VERSION"`
// PostgresImage and MySQLImage are the database servers the phase runs in
// the test namespace.
PostgresImage string `env:"E2E_POSTGRES_IMAGE"`
MySQLImage string `env:"E2E_MYSQL_IMAGE"`
// RegistryIP is the registry container's address on the kind network,
// RegistryService the Service that routes to it, and RegistryPort the
// host port the driver published it on.
RegistryIP string `env:"E2E_REGISTRY_IP"`
RegistryService string `env:"E2E_REGISTRY_SERVICE"`
RegistryPort string `env:"E2E_REGISTRY_PORT"`
// RegistryCredentialsFile holds the registry's username and password.
RegistryCredentialsFile string `env:"E2E_REGISTRY_CREDENTIALS_FILE"`
// DockerContext is the remote Docker daemon the registry and the external
// PostgreSQL run on, and RegistryContainerID the registry container the
// outage row stops.
DockerContext string `env:"E2E_DOCKER_CONTEXT"`
RegistryContainerID string `env:"E2E_REGISTRY_CONTAINER_ID"`
// The external PostgreSQL: a container outside Kubernetes that a
// selectorless Service routes to.
ExternalPostgresContainerID string `env:"E2E_EXTERNAL_POSTGRES_CONTAINER_ID"`
ExternalPostgresIP string `env:"E2E_EXTERNAL_POSTGRES_IP"`
ExternalPostgresService string `env:"E2E_EXTERNAL_POSTGRES_SERVICE"`
ExternalPostgresImage string `env:"E2E_EXTERNAL_POSTGRES_IMAGE"`
ExternalPostgresOwner string `env:"E2E_EXTERNAL_POSTGRES_OWNER"`
ExternalPostgresCredentialsFile string `env:"E2E_EXTERNAL_POSTGRES_CREDENTIALS_FILE"`
// The authenticated HTTPS registry proxy: its Service and the CA,
// certificate and key the driver generated for it.
TLSProxyService string `env:"E2E_TLS_PROXY_SERVICE"`
TLSProxyCAFile string `env:"E2E_TLS_PROXY_CA_FILE"`
TLSProxyCertFile string `env:"E2E_TLS_PROXY_CERT_FILE"`
TLSProxyKeyFile string `env:"E2E_TLS_PROXY_KEY_FILE"`
// Mode is full or prepare. The migration suites run the phase in prepare,
// for the namespace it stands up and none of its own acceptance.
Mode string `env:"E2E_DATAPLANE_MODE"`
}
DataPlaneInputs is what the driver hands the data-plane phase.
type HAInputs ¶
type HAInputs struct {
// Kubeconfig names the cluster the driver stood up.
Kubeconfig string `env:"E2E_KUBECONFIG"`
// OperatorNamespace is the release namespace.
OperatorNamespace string `env:"E2E_OPERATOR_NAMESPACE"`
// HATestNamespace is the namespace the phase creates its operation in,
// and removes.
HATestNamespace string `env:"E2E_HA_TEST_NAMESPACE"`
// ForeignNamespace and ProofNamespace are namespaces the manager's Lease
// grant must not reach.
ForeignNamespace string `env:"E2E_FOREIGN_NAMESPACE"`
ProofNamespace string `env:"E2E_PROOF_NAMESPACE"`
// HelmRelease is the installed release.
HelmRelease string `env:"E2E_HELM_RELEASE"`
// RegistryCredentialsFile holds the registry's username and password,
// which the operation Pod pulls its images with.
RegistryCredentialsFile string `env:"E2E_REGISTRY_CREDENTIALS_FILE"`
}
HAInputs is what the driver hands the high-availability phase.
type MigrationsInputs ¶
type MigrationsInputs struct {
// Kubeconfig names the cluster the driver stood up.
Kubeconfig string `env:"E2E_KUBECONFIG"`
// TestNamespace is the namespace the data plane stood up in preparation:
// its registry Service, its databases and its admission fixtures.
TestNamespace string `env:"E2E_TEST_NAMESPACE"`
// ExecutorImage publishes the migration artifacts, with the command a
// person would use.
ExecutorImage string `env:"E2E_EXECUTOR_IMAGE"`
// PtahVersion is the driver's declaration of the pinned executor build.
PtahVersion string `env:"E2E_PTAH_VERSION"`
// RunnerImage is the runner image the migration Jobs carry.
RunnerImage string `env:"E2E_RUNNER_IMAGE"`
// FixtureImage carries the isolated unsupported-runner publisher.
FixtureImage string `env:"E2E_FIXTURE_IMAGE"`
// ControllerImage is the candidate manager image, pinned by digest.
ControllerImage string `env:"E2E_CONTROLLER_IMAGE"`
// ControllerRevision is the commit the candidate was built from.
ControllerRevision string `env:"E2E_CONTROLLER_REVISION"`
// ControllerStateVersion is the controller-state version the chart was
// stamped with.
ControllerStateVersion string `env:"E2E_CONTROLLER_STATE_VERSION"`
// RegistryService is the Service the cluster reaches the registry by.
RegistryService string `env:"E2E_REGISTRY_SERVICE"`
// RegistryHostAddress is the same registry as the host reaches it, for the
// one artifact no product command can produce.
RegistryHostAddress string `env:"E2E_REGISTRY_HOST_ADDRESS"`
// RegistryCredentialsFile holds the registry's username and password.
RegistryCredentialsFile string `env:"E2E_REGISTRY_CREDENTIALS_FILE"`
// DockerContext and KindClusterName reach the isolation worker's node
// container, which the phase cuts off from the API server.
DockerContext string `env:"E2E_DOCKER_CONTEXT"`
KindClusterName string `env:"E2E_KIND_CLUSTER_NAME"`
// Engine is postgresql or mysql, and has to be the phase's own.
Engine string `env:"E2E_ENGINE"`
}
MigrationsInputs is what the driver hands the migration phases. Each phase runs one engine, and the driver names it: a phase that fell back to one engine because nobody named one would be coverage nobody noticed was gone.
type Of ¶
Of is a phase whose inputs are T. The harness takes one and returns a T, so the type of what a phase reads is decided where the phase is declared.
type Phase ¶
type Phase struct {
// Name is the phase as run_recorded_phase and the suite catalog spell it.
Name string
// Test is the test function in test/e2e that is the phase. The binary runs
// that function and nothing else when it is asked for the phase.
Test string
// Timeout bounds the whole phase. It sits above the sum of the phase's own
// waits, so it is a backstop for a call that hangs rather than a deadline
// any wait relies on.
Timeout time.Duration
// Scenarios are the stages the phase records in the timing ledger, in the
// order it runs them. The harness refuses one out of order and fails a
// phase that ends without running all of them.
Scenarios []string
// IsolatesNode says the full phase faults the isolation worker's API
// connection, so only a suite that declares that worker may run it.
// These faults run after the Preparation boundary, when one exists.
IsolatesNode bool
// Preparation is how many of the leading scenarios make up the phase's
// preparation mode: what another suite runs it for, the objects it stands
// up, and none of its own acceptance. Zero means the phase has no such
// mode. A run that stopped at the boundary proved those scenarios alone.
Preparation int
// RequiresFull names earlier phases whose completed acceptance leaves
// fixtures this phase uses. These dependencies apply when this phase runs
// in full; its preparation prefix must stand on its own. Running a required
// phase only through its own preparation boundary is insufficient.
RequiresFull []string
// contains filtered or unexported fields
}
Phase is one acceptance phase the Go harness carries.
type ReferenceDataInputs ¶
type ReferenceDataInputs struct {
// Kubeconfig names the cluster the driver stood up.
Kubeconfig string `env:"E2E_KUBECONFIG"`
// TestNamespace is the namespace the data plane stood up in preparation:
// its registry Service, its databases and its registry credentials.
TestNamespace string `env:"E2E_TEST_NAMESPACE"`
// OperatorNamespace is the release namespace, whose controller log the
// phase scans for declared row values.
OperatorNamespace string `env:"E2E_OPERATOR_NAMESPACE"`
// ExecutorImage publishes the reference-data artifacts, with the command a
// person would use.
ExecutorImage string `env:"E2E_EXECUTOR_IMAGE"`
// RunnerImage is the runner image the operation Jobs carry.
RunnerImage string `env:"E2E_RUNNER_IMAGE"`
// RegistryService is the Service the cluster reaches the registry by.
RegistryService string `env:"E2E_REGISTRY_SERVICE"`
// Engine is postgresql or mysql, and has to be the phase's own.
Engine string `env:"E2E_ENGINE"`
}
ReferenceDataInputs is what the driver hands the reference-data phases. They run in the namespace the data plane stood up, on its database servers, each on a database of its own that no other phase touched.
type UninstallInputs ¶
type UninstallInputs struct {
// Kubeconfig names the cluster the driver stood up.
Kubeconfig string `env:"E2E_KUBECONFIG"`
// DebugLogs is 1 to print the stderr of a refused Helm operation, and 0
// otherwise.
DebugLogs string `env:"E2E_DEBUG_LOGS"`
// OperatorNamespace is the release namespace.
OperatorNamespace string `env:"E2E_OPERATOR_NAMESPACE"`
// ProofNamespace holds the objects the upgrade phase created, which every
// step here has to leave exactly as they were.
ProofNamespace string `env:"E2E_PROOF_NAMESPACE"`
// HelmRelease is the installed release.
HelmRelease string `env:"E2E_HELM_RELEASE"`
// ChartPackage and CandidateValuesFile are the current release, which the
// phase rolls back to and installs again from its exact bytes.
ChartPackage string `env:"E2E_CHART_PACKAGE"`
CandidateValuesFile string `env:"E2E_CANDIDATE_VALUES_FILE"`
// ControllerImage is the candidate manager image, pinned by digest.
ControllerImage string `env:"E2E_CONTROLLER_IMAGE"`
// NextChartPackage, NextValuesFile and NextControllerImage are the
// synthetic next release the phase upgrades to.
NextChartPackage string `env:"E2E_NEXT_CHART_PACKAGE"`
NextValuesFile string `env:"E2E_NEXT_VALUES_FILE"`
NextControllerImage string `env:"E2E_NEXT_CONTROLLER_IMAGE"`
// KubernetesVersion is the exact version the cluster has to report.
KubernetesVersion string `env:"E2E_KUBERNETES_VERSION"`
// RegistryCredentialsFile holds the registry's username and password,
// which the running Apply's Pod pulls its images with.
RegistryCredentialsFile string `env:"E2E_REGISTRY_CREDENTIALS_FILE"`
// DockerContext and ExternalPostgresContainerID reach the external
// PostgreSQL, where the running Apply's barrier holds its lock.
DockerContext string `env:"E2E_DOCKER_CONTEXT"`
ExternalPostgresContainerID string `env:"E2E_EXTERNAL_POSTGRES_CONTAINER_ID"`
// ExternalPostgresIP and ExternalPostgresCredentialsFile are the address
// and credentials the running Apply connects with.
ExternalPostgresIP string `env:"E2E_EXTERNAL_POSTGRES_IP"`
ExternalPostgresCredentialsFile string `env:"E2E_EXTERNAL_POSTGRES_CREDENTIALS_FILE"`
}
UninstallInputs is what the driver hands the uninstall phase, which runs last on the cluster the upgrade phase leaves.
type UpgradeInputs ¶
type UpgradeInputs struct {
// Kubeconfig names the cluster the driver stood up.
Kubeconfig string `env:"E2E_KUBECONFIG"`
// DebugLogs is 1 to print the stderr of a refused Helm operation, and 0
// otherwise. The driver refuses 1 on CI, where the run log is public.
DebugLogs string `env:"E2E_DEBUG_LOGS"`
// OperatorNamespace is the release namespace.
OperatorNamespace string `env:"E2E_OPERATOR_NAMESPACE"`
// ProofNamespace holds the schema, plan and approval whose preservation
// the phase proves across every CRD change.
ProofNamespace string `env:"E2E_PROOF_NAMESPACE"`
// HelmRelease is the installed release.
HelmRelease string `env:"E2E_HELM_RELEASE"`
// ChartPackage is the chart the release was installed from.
ChartPackage string `env:"E2E_CHART_PACKAGE"`
// CandidateValuesFile is the values file the release was installed with.
CandidateValuesFile string `env:"E2E_CANDIDATE_VALUES_FILE"`
// ControllerImage is the candidate manager image, pinned by digest.
ControllerImage string `env:"E2E_CONTROLLER_IMAGE"`
// KubernetesVersion is the exact version the cluster has to report.
KubernetesVersion string `env:"E2E_KUBERNETES_VERSION"`
}
UpgradeInputs is what the driver hands the upgrade phase, which proves the CRD upgrade path of the release the driver installed.