Managing Edge

Modifying Edge

For this example, assume that the Edge is deployed using the c8yedge-sample.yaml.

Example configuration change

Change the spec.domain field to sample.myown.iot.com and if required update the spec.licenseKey accordingly.

Save the file and use the command below to apply the changes:

kubectl apply -f c8yedge-sample.yaml

To verify the Edge deployment, see Verifying the Edge installation.

Upgrading Edge

The Edge operator follows the recreate update strategy to upgrade the Edge deployment.

Recreating update strategy is an all-or-nothing process that updates all aspects of the system at once with a brief downtime period. The Edge operator selects all the outdated pods and deactivates them at once. Once all old pods are deactivated, the Edge operator creates updated pods for the entire system. Edge is not operational while the old pods are deactivating and until the final updated pod is created.

For this example, assume that Edge is deployed using the c8yedge-sample.yaml.

Upgrading from Edge version 10.18

Before upgrading Edge to 2025, run the following command to patch the c8yedge-operator-manager-role ClusterRole with the necessary permissions:

kubectl patch clusterrole c8yedge-operator-manager-role --type='json' --patch "$(curl -s https://cumulocity.com/docs/2025/files/edge-k8s/c8yedge-operator-cluster-role-patch-1018.yaml)"

This step is required to ensure the Edge operator can properly enforce validation and mutation rules when updating the Edge CR.

Why this change is needed?

The Edge operator version 2025 leverages the admission webhooks feature of Kubernetes to enhance validation and enforce default configurations for the Edge CR.

The Edge operator to leverage the admission webhooks requires additional permissions, which the above command applies.

Starting the upgrade

To upgrade the Edge deployment, change the spec.version field in the Edge CR file to the appropriate version. For example to 2025.0.1.

Save the file and use the command below to apply the changes:

kubectl apply -f c8yedge-sample.yaml

To verify the Edge deployment, see Verifying the Edge installation.

Upgrading Edge remotely

For information about upgrading Edge remotely, see Upgrading Edge remotely.

Restarting the Edge operator

Run this command to restart the Edge operator.

kubectl rollout restart deployment -n c8yedge c8yedge-operator-controller-manager
Info
Substitute the namespace name c8yedge in the command above with the namespace name where you have installed the Edge operator.

Upgrading the Edge operator

The Edge operator, once installed, will automatically upgrade when you upgrade Edge to a new version.

Uninstalling Edge

You can uninstall Edge either by:

  • Deleting the Edge Custom Resource using the command:

    kubectl delete edge c8yedge -n c8yedge
    
  • Through the c8yedge-sample.yaml that you used to install Edge.

    For example, you can uninstall by using the command:

    kubectl delete -f c8yedge-sample.yaml
    
    Info
    Substitute the namespace name c8yedge in the command above with the specific namespace name you have specified in your Edge CR.

Uninstalling the Edge operator

Run this command for removing the Edge operator from your Kubernetes cluster.

helm uninstall c8yedge-operator -n c8yedge
Info
Substitute the namespace name c8yedge in the command above with the namespace name where you have installed the Edge operator.