Skip to main content
Version: Deploy 24.3

Updating LDAP Configuration in Digital.ai Deploy Pods

This topic provides step-by-step instructions for updating the deployit-security.xml file for Digital.ai Deploy, both for the master and worker pods. For more information, see Set up and configure LDAP with Deploy.

The following configuration assumes that Digital.ai Deploy is installed in the digitalai namespace, with the configuration stored in the Custom Resource (CR) named dai-xld.

Set up LDAP in Deploy operator

Master Pod

  1. Download the latest template configuration file by running the following command.
kubectl cp -c deploy-master \
digitalai/dai-xld-digitalai-deploy-master-0:default-conf/deployit-security.xml \
deployit-security.xml
  1. Create a patch file with the downloaded template file added under content key.
vi deployit-security.xml.patch.yaml

For example,

spec:
master:
extraConfiguration:
default-conf_deployit-security_xml:
path: default-conf/deployit-security.xml
content: |-
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
</beans>
  1. Go to conf directory, backup old deployit-security.xml from the pod.
kubectl cp -c deploy-master \
digitalai/dai-xld-digitalai-deploy-master-0:conf/deployit-security.xml \
backup/deployit-security.xml
  1. Update the configuration on the Deploy pods by running the following command. In this example, the name of CR is dai-xld.
kubectl patch -n digitalai digitalaideploys.xld.digital.ai dai-xld \
--type=merge --patch-file deployit-security.xml.patch.yaml

The updated CR will trigger after some time. Wait for a minute to reconcile changes.

  1. Restart the Deploy master pods by deleting them.
kubectl delete sts dai-xld-digitalai-deploy-master -n digitalai
  1. Verify that the restarted deploy master pods are using the new configuration.
kubectl exec -it sts/dai-xld-digitalai-deploy-master -n digitalai \
-- cat /opt/xebialabs/xl-deploy-server/conf/deployit-security.xml

Worker Pod

  1. Download the latest template configuration file by running the following command:
kubectl cp -c deploy-worker \
digitalai/dai-xld-digitalai-deploy-worker-0:default-conf/deployit-security.xml \
deployit-security.xml
  1. Create a patch file with the downloaded template file.
vi deployit-security.xml.patch.yaml

For example,

spec:
worker:
extraConfiguration:
default-conf_deployit-security_xml:
path: default-conf/deployit-security.xml
content: |-
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
</beans>
  1. Go to conf directory, backup old deployit-security.xml from the pod.
kubectl cp -c deploy-worker \
digitalai/dai-xld-digitalai-deploy-worker-0:conf/deployit-security.xml \
backup/deployit-security.xml
  1. Update the configuration on the Deploy pods by running the following command. In this example, the name of CR is dai-xld.
kubectl patch -n digitalai digitalaideploys.xld.digital.ai dai-xld \
--type=merge --patch-file deployit-security.xml.patch.yaml

The updated CR will trigger after some time.Wait for a minute to reconcile changes.

  1. Restart the Deploy worker pods by deleting them.
kubectl delete sts dai-xld-digitalai-deploy-worker -n digitalai
  1. Verify that the restarted Deploy worker pods are using the new configuration.
kubectl exec -it sts/dai-xld-digitalai-deploy-worker -n digitalai \
-- cat /opt/xebialabs/deploy-task-engine/conf/deployit-security.xml