Environment Variables
Purpose: For platform engineers, provides the environment variables the CLI reads and clarifies which ones belong to GA infrastructure providers versus service integrations.
Precedence
When the same setting is available through multiple sources, the CLI resolves in this order (highest wins):
- CLI
--setflags - Environment variables
- Config file values
- Schema defaults
CLI Variables
| Variable | Description | Default |
|---|---|---|
OPENCENTER_CLUSTER | Active cluster name | Set by opencenter cluster select |
OPENCENTER_CONFIG_DIR | Root configuration directory | ~/.config/opencenter |
OPENCENTER_LOG_LEVEL | Log verbosity: debug, info, warn, error | warn |
EDITOR | Editor for opencenter cluster edit | vi |
KIND_EXPERIMENTAL_PROVIDER | Optional Kind runtime override for Podman | unset |
OPENCENTER_LOG_LEVEL
Controls CLI log verbosity. Valid values: debug, info, warn, error.
Precedence (highest wins):
--log-levelflagOPENCENTER_LOG_LEVELenvironment variable- Default:
warn
The CLI checks whether --log-level was explicitly set. If the flag is at its default value (warn), the CLI reads OPENCENTER_LOG_LEVEL from the environment. If the env var is set, that value is used. If neither the flag nor the env var is provided, the default warn applies.
# Use env var (no flag)
export OPENCENTER_LOG_LEVEL=debug
opencenter cluster list # runs at debug level
# Flag overrides env var
export OPENCENTER_LOG_LEVEL=debug
opencenter cluster list --log-level error # runs at error level
# Default when neither is set
unset OPENCENTER_LOG_LEVEL
opencenter cluster list # runs at warn level
Cluster Variables (set by opencenter cluster env)
| Variable | Description |
|---|---|
OPENCENTER_CLUSTER | Currently active cluster identifier |
KUBECONFIG | Path to cluster kubeconfig file |
ANSIBLE_INVENTORY | Path to Kubespray inventory file |
PATH | Prepended with cluster-specific bin/ directory |
OpenStack Provider Variables
| Variable | Description |
|---|---|
OS_AUTH_URL | Keystone authentication URL |
OS_PROJECT_NAME | OpenStack project name |
OS_USERNAME | OpenStack username |
OS_PASSWORD | OpenStack password |
OS_REGION_NAME | OpenStack region |
OS_USER_DOMAIN_NAME | User domain |
OS_PROJECT_DOMAIN_NAME | Project domain |
VMware Variables
| Variable | Description |
|---|---|
VSPHERE_SERVER | vCenter server address |
VSPHERE_USER | vCenter username |
VSPHERE_PASSWORD | vCenter password |
These are relevant to VMware integrations such as vSphere CSI and related credential flows.
Kind Runtime Variable
KIND_EXPERIMENTAL_PROVIDER
Selects a non-default local runtime for Kind, typically Podman:
export KIND_EXPERIMENTAL_PROVIDER=podman
opencenter cluster bootstrap dev-cluster
AWS Service Integration Variables
AWS remains relevant for service integrations, but not as a GA infrastructure provider.
| Variable | Description |
|---|---|
AWS_ACCESS_KEY_ID | AWS access key |
AWS_SECRET_ACCESS_KEY | AWS secret key |
AWS_DEFAULT_REGION | AWS region |
Air-Gap Variables (config/versions.env)
| Variable | Description |
|---|---|
KUBERNETES_VERSION | Target Kubernetes version |
KUBESPRAY_VERSION | Kubespray branch or tag |
CONTAINERD_VERSION | ContainerD version |
CALICO_VERSION | Calico CNI version |
OPENCENTER_GITOPS_BASE_REPO | Git URL for gitops-base |
OPENCENTER_GITOPS_BASE_VERSION | Branch or tag for gitops-base |
TARGET_ARCH | Target architecture (amd64, arm64) |
Shell Integration
# Bash/Zsh
eval "$(opencenter cluster env my-cluster)"
# Fish
opencenter cluster env my-cluster --shell fish | source
# PowerShell
opencenter cluster env my-cluster --shell powershell | Invoke-Expression