Errors during OpenShift upgrade with custom SCCs

이 페이지는 아직 영어로 제공되지 않습니다. 번역 작업 중입니다.
현재 번역 프로젝트에 대한 질문이나 피드백이 있으신 경우 언제든지 연락주시기 바랍니다.

When upgrading OpenShift Container Platform (OCP) from 4.11 to 4.12 with Datadog installed on your cluster, you may encounter the following error for the package-server-manager pod:

deployment openshift-operator-lifecycle-manager/package-server-manager has a
replica failure FailedCreate: pods "package-server-manager-12a3b4cd5e-1x2y3" is
forbidden: violates PodSecurity "restricted:v1.24": seLinuxOptions (pod set
forbidden securityContext.seLinuxOptions: type "spc_t"; user may not be set;
role may not be set)

This error occurs if custom Security Context Constraints (SCCs), such as Datadog’s custom SCC, are present in the cluster.

Workaround

  1. Back up the datadog SCC to datadog_scc.yaml:

    oc get scc datadog -n <NAMESPACE> -o yaml > datadog_scc.yaml
    

    Replace <NAMESPACE> with the name of your project namespace.

  2. Remove the datadog SCC:

    oc delete scc datadog -n <NAMESPACE>
    

    Replace <NAMESPACE> with the name of your project namespace.

  3. Finish upgrading your cluster.

  4. Recreate the SCC from your backup file:

    oc create -f datadog_scc.yaml