Differences Between oc and kubectl
Although there are several similarities between these two clients, this guide’s aim is to clarify the main reasons and scenarios for using one over the other.
The oc
binary offers the same capabilities as the kubectl
binary, but it is further extended to natively support OKD features, such as:
Full support for OpenShift resources
Authentication
The oc
binary offers a built-in login
command which allows authentication. See developer authentication and for more information.
Additional commands
The kubectl
binary is provided as a means to support existing workflows and scripts for new OKD users coming from a standard Kubernetes environment. Existing users of can continue to use the binary with no changes to the API, but should consider upgrading to oc
in order to gain the added functionality mentioned in the previous section.
Because oc
is built on top of kubectl
, converting a kubectl
binary to oc
is as simple as changing the binary’s name from kubectl
to .
See Get Started with the CLI for installation and setup instructions.