Changing the database password¶
You can change the password for the Anaconda Enterprise database as needed, to adhere to your organization’s policies. To do so, you’ll need to connect to the associated pod, make the change, and update the platform with the new password.
Run the following command to determine the id of the postgres pod:
kubectl get pod | grep postgres
Run the following command to connect to the postgres pod, where
<id>represents the id of the pod:
kubectl exec -it anaconda-enterprise-postgres-<id> /bin/sh
psqlcommand to connect to the database:
psql -h localhost -U postgres
Set the password by running the following command:
ALTER USER postgres WITH PASSWORD 'new_password';
To update the platform settings with the database password of the host server:
Access the Anaconda Enterprise Operations Center by entering this URL in your browser:
anaconda.example.comwith the FQDN of the host server.
Login with the default username and password:
aeplatform. You’ll be asked to change the default password when you log in.
Click Configuration in the left menu to display the Anaconda Enterprise Config map.
In the GLOBAL CONFIGURATION section of the configuration file, locate the
dbsection and enter the password you just set:
Click Apply to update the platform with your changes.
Restart all the service pods using the following command:
kubectl get pods | grep ap- | cut -d' ' -f1 | xargs kubectl delete pods