Configuring a custom EDB operator

version 4190 Configuring foundational services with a custom EDB operator is deprecated in foundational services version 4.19.0 and onward. In these versions, use IBM Postgres instead of EDB. For more information, see IBM Postgres settings.

version 490 From foundational services version 4.9, you can configure foundational services with the custom EDB operator before you install the IM or Zen services. These services use the custom EDB operator that is installed manually in the cluster. You can install the custom EDB operator in AllNamespaces mode or namespace where you deployed the foundational services operator (ibm-common-service-operator).

IBM does not provide support for the custom EDB operator. Ensure that your custom EDB operator installation is successful and usable with foundational services.

Prerequisites

  • Ensure that the foundational services operator (ibm-common-service-operator) is installed in your cluster.
  • Ensure that the OperandRequests are not created for the services such as Identity Management (IM) or Zen.

Procedure

You can configure the custom EDB operator with one of the following methods:

Configuring a custom EDB operator with the console

  1. Log in to your OpenShift console.

  2. Update the CommonService custom resource (CR) in the namespace where you deployed the foundational services. Complete the following steps to update the CommonService CR:

    1. From the navigation window, click Operators > Installed Operators.

    2. From the Project drop-down list, select foundational-services.

    3. Click IBM Cloud Pak foundational services .

    4. Select the CommonService tab. You can see the common-service custom resource instance.

    5. Click the common-service custom resource instance.

    6. Select the YAML tab.

    7. Add the opeartorConfigs parameter with the following values:

      apiVersion: operator.ibm.com/v3
      kind: CommonService
      metadata:
        name: common-service
      spec:
        operatorConfigs:
          - name: cloud-native-postgresql
            userManaged: true
       

      Set the value of userManaged parameter with true to configure your cluster with the custom EDB operator.

    8. Click Save.

    If you install IM or Zen after you configure the cluster with custom EDB operator, the foundational services uses the custom EDB operator.

  3. If you installed foundational services with a Helm chart, create a cloud-native-postgresql-operand-images-config ConfigMap in your designated operator namespace.
    1. Download the CASE version that your IBM Cloud PakĀ® uses.
      Export the CASE name and version:
      export CASE_NAME=ibm-cloud-native-postgresql
      export CASE_VERSION=<your-postgresql-version>
      Download the CASE with the oc ibm-pak get command:
      oc ibm-pak get $CASE_NAME --version $CASE_VERSION --install-method helm
    2. Locate the Helm chart archive. See the following example command to list the downloaded chart files in the archive.
      • In this example, the 5.30.0 value is the requested CASE version.
      • The 5.30.0+20251203.182305.2683 value is the resolved CASE build directory that is created locally.
      • The postgresql-5.30.0+20251203.094351.155.tgz file is the Helm chart package for the release.
      ls ~/.ibm-pak/data/cases/ibm-cloud-native-postgresql/5.30.0+20251203.182305.2683/charts/postgresql-5.30.0+20251203.094351.155.tgz
      If you don't know the resolved CASE build directory name, list the available directories:
      ls ~/.ibm-pak/data/cases/ibm-cloud-native-postgresql/
      Then, list the chart files under the resolved version:
      ls ~/.ibm-pak/data/cases/ibm-cloud-native-postgresql/<resolved-case-build>/charts/
    3. Create a working directory and extract the Helm chart:
      mkdir -p /tmp/ibm-cloud-native-postgresql
      tar -xzf ~/.ibm-pak/data/cases/ibm-cloud-native-postgresql/<resolved-case-build>/charts/postgresql-<chart-version>.tgz -C /tmp/ibm-cloud-native-postgresql
    4. Find the operand images ConfigMap template:
      ls /tmp/ibm-cloud-native-postgresql/postgresql/templates/operandimagelist.yaml
    5. Render the ConfigMap from the Helm chart. Render the chart locally with the command and save the rendered ConfigMap to a file:
      export IMAGE_REGISTRY="myregistry.company.com"
      export IMAGE_NAMESPACE_OPERAND="cpopen/edb"
      export IMAGE_NAMESPACE_ENTITLED="cp/cpd"
      export OPERATOR_NAMESPACE="your-operator-namespace"
      export OPERAND_NAMESPACE="your-operand-namespace"
      
      helm template ibm-cloud-native-postgresql /tmp/ibm-cloud-native-postgresql/postgresql \
        --set global.operatorNamespace=${OPERATOR_NAMESPACE} \
        --set global.instanceNamespace=${OPERAND_NAMESPACE} \
        --set global.imagePullPrefix=${IMAGE_REGISTRY} \
        --set postgresql.imageRegistryNamespaceOperand=${IMAGE_NAMESPACE_OPERAND} \
        --set postgresql.entitledImageRegistryNamespace=${IMAGE_NAMESPACE_ENTITLED} \
        | awk '/^# Source: .*operandimagelist.yaml/{flag=1;next}/^---$/{if(flag){exit}}flag' \
        > operandimagelist.yaml
    6. Verify the rendered manifest.
      Check that the rendered file contains the expected resource:
      cat operandimagelist.yaml
      The output includes the following elements:
      kind: ConfigMap
        name: cloud-native-postgresql-operand-images-config
    7. To apply the rendered ConfigMap to the OpenShift cluster, apply the ConfigMap to the target namespace:
      oc apply -f operandimagelist.yaml
    8. Confirm the ConfigMap on the cluster. Verify that the ConfigMap exists and contains the rendered image references:
      oc get configmap cloud-native-postgresql-operand-images-config -n $OPERATOR_NAMESPACE -o yaml
  4. version 4170 version 4180 If you use foundational services versions 4.17.0 or 4.18.0, run the following command so that the custom EDB configuration in the CommonService CR is applied:
    oc get operandregistry common-service -n ${PROJECT_CPD_INST_OPERANDS} -o yaml \
    | yq '(.spec.operators[] | select(.packageName == "cloud-native-postgresql") | .userManaged) = true' \
    | oc apply -f -

Configuring a custom EDB operator with CLI

  1. Log in to the cluster by using the oc login command.

  2. Edit the common-service custom resource instance.

    oc edit CommonService common-service -n <your-foundational-services-namespace>
     

    Replace <your-foundational-services-namespace> with the namespace where you deployed the foundational services.

  3. Add the opeartorConfigs parameter with the following values:

       apiVersion: operator.ibm.com/v3
       kind: CommonService
       metadata:
         name: common-service
       spec:
         operatorConfigs:
           - name: cloud-native-postgresql
             userManaged: true
     

    Set the value of userManaged parameter with true to configure your cluster with the custom EDB operator.

  4. Apply the YAML file.

    oc apply -f common-service.yaml
     
  5. If you installed the ibm-common-service-operator foundational services operator with Helm, create the ConfigMap manually.
    1. Download the CASE version that your IBM Cloud PakĀ® uses.
      Export the CASE name and version:
      export CASE_NAME=ibm-cloud-native-postgresql
      export CASE_VERSION=<your-postgresql-version>
      Download the CASE with the oc ibm-pak get command:
      oc ibm-pak get $CASE_NAME --version $CASE_VERSION --install-method helm
    2. Locate the Helm chart archive. See the following example command to list the downloaded chart files in the archive.
      • In this example, the 5.30.0 value is the requested CASE version.
      • The 5.30.0+20251203.182305.2683 value is the resolved CASE build directory that is created locally.
      • The postgresql-5.30.0+20251203.094351.155.tgz file is the Helm chart package for the release.
      ls ~/.ibm-pak/data/cases/ibm-cloud-native-postgresql/5.30.0+20251203.182305.2683/charts/postgresql-5.30.0+20251203.094351.155.tgz
      If you don't know the resolved CASE build directory name, list the available directories:
      ls ~/.ibm-pak/data/cases/ibm-cloud-native-postgresql/
      Then, list the chart files under the resolved version:
      ls ~/.ibm-pak/data/cases/ibm-cloud-native-postgresql/<resolved-case-build>/charts/
    3. Create a working directory and extract the Helm chart:
      mkdir -p /tmp/ibm-cloud-native-postgresql
      tar -xzf ~/.ibm-pak/data/cases/ibm-cloud-native-postgresql/<resolved-case-build>/charts/postgresql-<chart-version>.tgz -C /tmp/ibm-cloud-native-postgresql
    4. Find the operand images ConfigMap template:
      ls /tmp/ibm-cloud-native-postgresql/postgresql/templates/operandimagelist.yaml
    5. Render the ConfigMap from the Helm chart. Render the chart locally with the command and save the rendered ConfigMap to a file:
      export IMAGE_REGISTRY="myregistry.company.com"
      export IMAGE_NAMESPACE_OPERAND="cpopen/edb"
      export IMAGE_NAMESPACE_ENTITLED="cp/cpd"
      export OPERATOR_NAMESPACE="your-operator-namespace"
      export OPERAND_NAMESPACE="your-operand-namespace"
      
      helm template ibm-cloud-native-postgresql /tmp/ibm-cloud-native-postgresql/postgresql \
        --set global.operatorNamespace=${OPERATOR_NAMESPACE} \
        --set global.instanceNamespace=${OPERAND_NAMESPACE} \
        --set global.imagePullPrefix=${IMAGE_REGISTRY} \
        --set postgresql.imageRegistryNamespaceOperand=${IMAGE_NAMESPACE_OPERAND} \
        --set postgresql.entitledImageRegistryNamespace=${IMAGE_NAMESPACE_ENTITLED} \
        | awk '/^# Source: .*operandimagelist.yaml/{flag=1;next}/^---$/{if(flag){exit}}flag' \
        > operandimagelist.yaml
    6. Verify the rendered manifest.
      Check that the rendered file contains the expected resource:
      cat operandimagelist.yaml
      The output includes the following elements:
      kind: ConfigMap
        name: cloud-native-postgresql-operand-images-config
    7. To apply the rendered ConfigMap to the OpenShift cluster, apply the ConfigMap to the target namespace:
      oc apply -f operandimagelist.yaml
    8. Confirm the ConfigMap on the cluster. Verify that the ConfigMap exists and contains the rendered image references:
      oc get configmap cloud-native-postgresql-operand-images-config -n $OPERATOR_NAMESPACE -o yaml
  6. version 4170 version 4180 If you use foundational services versions 4.17.0 or 4.18.0, run the following command so that the custom EDB configuration in the CommonService CR is applied:
    oc get operandregistry common-service -n ${PROJECT_CPD_INST_OPERANDS} -o yaml \
    | yq '(.spec.operators[] | select(.packageName == "cloud-native-postgresql") | .userManaged) = true' \
    | oc apply -f -