-
Notifications
You must be signed in to change notification settings - Fork 16
Description
Summary
Replace oc CLI usage with kubectl for standard Kubernetes operations throughout the codebase. The oc CLI should be retained only where OpenShift-specific subcommands are required (e.g., oc adm release info, oc adm release new, oc adm policy add-scc-to-group).
Motivation
This is an upstream/OKD project designed to work without Red Hat subscriptions. Depending on oc for basic get nodes/pods operations introduces an unnecessary dependency on the OpenShift CLI when kubectl (already bundled with MicroShift) is fully sufficient.
The codebase already uses kubectl in some places (e.g., src/cncf/run_sonobuoy_tests.sh, src/deb/install.sh), creating inconsistency. The DEB install script even creates a symlink from kubectl → oc because oc isn't available on Debian, highlighting this friction.
Scope
Replace oc → kubectl in:
src/cluster_manager.sh—oc get nodes,pods -A -o widesrc/quickrpm.sh—oc get pods -A(in echo/usage text)src/quickstart.sh—oc get pods -A(in echo/usage text)docs/run-bootc.md—oc get nodes,oc get pods -Adocs/run.md—oc get pods -Asrc/etcd/README.md—oc get nodes,oc get pods -A.claude/agents/microshift-deployer.md— "Use kubectl and oc commands" reference
Keep oc as-is in (no kubectl equivalent):
src/image/prebuild.sh—oc adm release info(OKD release inspection)src/okd/build_images.sh—oc adm release new,oc adm release info(OKD image building)src/cncf/run_sonobuoy_tests.sh—oc adm policy add-scc-to-group(OpenShift SCC management)
Review and simplify:
src/deb/install.sh— Currently createskubectl → ocsymlink; after this change, the symlink may no longer be needed for runtime usage (but may still be needed for build-time scripts that useoc adm)
Acceptance Criteria
- All standard Kubernetes CLI invocations use
kubectlinstead ofoc -
ocis only used for OpenShift-specific subcommands (oc adm release info/new,oc adm policy) - Documentation reflects the change
-
make checkpasses (linters)