preflight-<date>T<time>.log) and cleanup(
preflight_cleanup-<date>T<time>.log) which can be used to get more information around operations being performed by this plugin.
bash(>=v3.2.x) should be present on system.
kubectlis not installed and
ocbinary is installed on host machine, then
ocbinary can be used to perform
kubectloperation by creating symlink with:
UIDis generated for that particular preflight check. This
UIDis the value of the label
preflight-run, which is set on every resource created during the preflight check. Also the
UIDis the suffix of name of every resource created during preflight check. This
UIDis particularly useful to perform cleanup of resources created during a particular preflight check. The following checks are included in preflight:
check-kubectl- Ensures kubectl utility is present on system. This check is skipped if the
--in-clusterflag is enabled.
check-cluster-access- Ensures preflight can access the remote target cluster.
--in-clusterflag is enabled.
check-kubernetes-version- Ensures minimum Kubernetes version >= 1.19.x
check-kubernetes-rbac- Ensures RBAC is enabled in cluster
storageclass.provisioner] should match with provided volumeSnapshotClass's
[i]will be selected. If there's are multiple volumeSnapshotClasses satisfying condition
[i], default volumeSnapshotClass[which has annotation
snapshot.storage.kubernetes.io/is-default-class: "true"set] will be used for further pre-flight checks.
check_volume_snapshotcheck is skipped.
version=v1.x.x[update with your desired version]. If
versionis not exported,
latesttagged version will be considered.
kubectl tvk-preflight --help
local-registryflag, it is mandatory to have
dnsutils:1.3images (with the same tags) to be there in the private registry.
Steps for pushing images to local registry
docker push <local registry/image>
docker push localhost:5000/busybox
--volume-snapshot-class: Performs preflight checks on the cluster with the given volumeSnapshotClass in the given namespace.
--service-account: Performs preflight checks on the cluster with the given local-registry and service-account in the given namespace.
--image-pull-secret: To use image-pull-secret, local-registry flag value must be provided. Vice-versa is not true.
--cleanup-on-failure: If preflight checks fail, the resources generated during preflight will be cleaned.
--requests: A resource request is specified in key-value format, joined by
=. Multiple resource requests can be specified in a comma separated format.
--limits: A resource limit is specified in key-value format, joined by
=. Multiple resource limits can be specified in a comma separated format.
--node-selector: Multiple labels for node selection can be specified in a comma separated format. Where each label can be specified in a format
namespaceis not specified then, cleanup will be performed in default namespace of the cluster.