Install the operator

The operator uses Helm to create and deploy the necessary resources and then run the operator in a Kubernetes cluster. This document describes how to install, upgrade, and remove the operator.


Install the operator Helm chart

Use the helm install command to install the operator Helm chart. As part of this, you must specify a “release” name for the operator.

You can override default configuration values in the operator Helm chart by doing one of the following:

  • Creating a custom YAML file containing the values to be overridden, and specifying the --value option on the Helm command line.
  • Overriding individual values directly on the Helm command line, using the --set option.

You supply the –namespace argument from the helm install command line to specify the namespace in which the operator should be installed. If not specified, then it defaults to default. If the namespace does not already exist, then Helm will automatically create it (and create a default service account in the new namespace), but will not remove it when the release is deleted. If the namespace already exists, then Helm will re-use it. These are standard Helm behaviors.

Similarly, you may override the default serviceAccount configuration value to specify which service account in the operator’s namespace, the operator should use. If not specified, then it defaults to default (for example, the namespace’s default service account). If you want to use a different service account, then you must create the operator’s namespace and the service account before installing the operator Helm chart.

For example, using Helm 3.x:

$ kubectl create namespace weblogic-operator-namespace
$ helm install weblogic-operator kubernetes/charts/weblogic-operator \
  --namespace weblogic-operator-namespace \
  --values custom-values.yaml --wait


$ helm install weblogic-operator kubernetes/charts/weblogic-operator \
  --namespace weblogic-operator-namespace \
  --set "javaLoggingLevel=FINE" --wait

This creates a Helm release, named weblogic-operator in the weblogic-operator-namespace namespace, and configures a deployment and supporting resources for the operator.

You can verify the operator installation by examining the output from the helm install command.

For more information on specifying the registry credentials when the operator image is stored in a private registry, see Operator image pull secret.

Alternatively, install the operator Helm chart from the GitHub chart repository

Add this repository to the Helm installation:

$ helm repo add weblogic-operator

Verify that the repository was added correctly:

$ helm repo list
NAME           URL

Update with the latest information about charts from the chart repositories:

$ helm repo update

Install the operator from the repository:

$ helm install weblogic-operator weblogic-operator/weblogic-operator

Upgrade the operator

Because operator 3.0.0 introduces non-backward compatible changes, you cannot use helm upgrade to upgrade a 2.6.0 operator to a 3.x operator. Instead, you must delete the 2.6.0 operator and then install the 3.x operator.

The deletion of the 2.6.0 operator will not affect the Domain CustomResourceDefinition (CRD) and will not stop any WebLogic Server instances already running.

When the 3.x operator is installed, it will automatically roll any running WebLogic Server instances created by the 2.6.0 operator. This rolling restart will preserve WebLogic cluster availability guarantees (for clustered members only) similarly to any other rolling restart.

To delete the 2.6.0 operator:

$ helm delete weblogic-operator -n weblogic-operator-namespace

Then install the 3.x operator using the installation instructions above.

The following instructions will be applicable to upgrade operators within the 3.x release family as additional versions are released.

To upgrade the operator, use the helm upgrade command. When upgrading the operator, the helm upgrade command requires that you supply a new Helm chart and image. For example:

$ helm upgrade \
  --reuse-values \
  --set image=oracle/weblogic-kubernetes-operator:3.0.2 \
  --namespace weblogic-operator-namespace \
  --wait \
  weblogic-operator \

Remove the operator

The helm delete command is used to remove an operator release and its associated resources from the Kubernetes cluster. The release name used with the helm delete command is the same release name used with the helm install command (see Install the Helm chart). For example:

$ helm delete weblogic-operator -n weblogic-operator-namespace

If the operator’s namespace did not exist before the Helm chart was installed, then Helm will create it, however, helm delete will not remove it.

After removing the operator deployment, you should also remove the domain custom resource definition:

$ kubectl delete customresourcedefinition

Note that the domain custom resource definition is shared if there are multiple operators in the same cluster.