Konveyor Forklift controller.
For the build, the forklift uses Bazel.
Install the following system components:
- bazel >= 5
- gcc
- glibc-static
- podman (or docker)
The environment which you can set across all projects.
Name | Default value | Description |
---|---|---|
REGISTRY_TAG | devel | The tag with which the image will be built and pushed to the registry. |
REGISTRY_ORG | kubev2v | The registry organization to which the built image should be pushed. |
REGISTRY | quay.io | The registry address to which the images should be pushed. |
The environment variables that you can set in .bazelrc, these variables are used during Bazel build process and used inside the bazel sandbox.
Another option to override the default values can use --action_env
as in the example.
Name | Default value | Description |
---|---|---|
CONTAINER_CMD | autodetected | The container runtime command (e.g.: /usr/bin/podman) |
VERSION | 2.7.0 | The version with which the forklift should be built. |
NAMESPACE | konveyor-forklift | The namespace in which the operator should be installed. |
CHANNELS | development | The olm channels. |
DEFAULT_CHANNEL | development | The default olm channel. |
OPERATOR_IMAGE | quay.io/kubev2v/forklift-operator:latest | The forklift operator image with the ansible-operator role. |
CONTROLLER_IMAGE | quay.io/kubev2v/forklift-controller:latest | The forklift controller image. |
MUST_GATHER_IMAGE | quay.io/kubev2v/forklift-must-gather:latest | The forklift must gather an image. |
UI_PLUGIN_IMAGE | quay.io/kubev2v/forklift-console-plugin:latest | The forklift OKD/OpenShift UI plugin image. |
VALIDATION_IMAGE | quay.io/kubev2v/forklift-validation:latest | The forklift validation image. |
VIRT_V2V_IMAGE | quay.io/kubev2v/forklift-virt-v2v:latest | The forklift virt v2v image for cold migration. |
VIRT_V2V_WARM_IMAGE | quay.io/kubev2v/forklift-virt-v2v-warm:latest | The forklift virt v2v image for warm migration. |
POPULATOR_CONTROLLER_IMAGE | quay.io/kubev2v/populator-controller:latest | The forklift volume-populator controller image. |
OVIRT_POPULATOR_IMAGE | quay.io/kubev2v/ovirt-populator:latest | The oVirt populator image. |
export REGISTRY_ORG=organization
export REGISTRY=quay.io
export REGISTRY_TAG=latest
CONTROLLER_IMAGE=${REGISTRY}/${REGISTRY_ORG}/forklift-controller:${REGISTRY_TAG}
OPERATOR_IMAGE=${REGISTRY}/${REGISTRY_ORG}/forklift-operator:${REGISTRY_TAG}
# If YAML files are added/modified `bazel clean` needs to be performed before building the image for the change to take effect
bazel run push-forklift-operator
bazel run push-forklift-operator-bundle --action_env OPERATOR_IMAGE=${OPERATOR_IMAGE} --action_env CONTROLLER_IMAGE=${CONTROLLER_IMAGE}
# The build of the catalog requires already pushed bundle
# For http registry add --action_env OPM_OPTS="--use-http"
bazel run push-forklift-operator-index --action_env REGISTRY=${REGISTRY} --action_env REGISTRY_ORG=${REGISTRY_ORG} --action_env REGISTRY_TAG=${REGISTRY_TAG}
- Modify the image value under
operator/forklift-operator-catalog.yaml
to point to the desired forklift-operator-index image. - Run
oc create -f operator/forklift-operator-catalog.yaml
- A new Forklift operator should be available now in the OperatorHub (without community tag).
Logging can be configured using environment variables:
- LOG_DEVELOPMENT: Development mode with human readable logs and (default) verbosity=4.
- LOG_LEVEL: Set the verbosity.
Verbosity:
- Info(0) used for
Info
logging.- Reconcile begin, end, error.
- Condition added, update, deleted.
- Plan postponed.
- Migration (k8s) resources created, deleted.
- Migration started, stopped, run (with phase), canceled, succeeded, failed.
- Snapshot created , updated, deleted, changed.
- Inventory watch ensured.
- Policy agent disabled.
- Info(1) used for
Info+
logging.- Connection testing.
- Plan postpone details.
- Pending migration details.
- Migration (k8s) resources found, updated.
- Scheduler details.
- Info(2) used for
Info++
logging.- Full conditions list.
- Migrating VM status (full definition).
- Provider inventory data reconciler started, stopped.
- Info(3) used for
Info+++
logging.- Inventory watch: resources changed; queued reconcile events.
- Data reconciler: models created, updated, deleted.
- VM validation succeeded.
- Info(4) used for
Debug
logging.- Policy agent HTTP request.
The profiler can be enabled using the following environment variables:
- PROFILE_KIND: Kind of profile (memory|cpu|mutex).
- PROFILE_PATH: Profiler output directory.
- PROFILE_DURATION: The duration (minutes) the profiler will collect data. (0=indefinately)