From 78ca43a624ac6627fc41086214128a983a9c9a9e Mon Sep 17 00:00:00 2001 From: akumari Date: Fri, 15 Nov 2024 14:51:57 +0530 Subject: [PATCH] update migrate task --- roles/pulp/tasks/main.yaml | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/roles/pulp/tasks/main.yaml b/roles/pulp/tasks/main.yaml index 480c4f8..297e738 100644 --- a/roles/pulp/tasks/main.yaml +++ b/roles/pulp/tasks/main.yaml @@ -127,17 +127,22 @@ ansible.builtin.systemd: daemon_reload: true +- name: Migrate the Pulp database + containers.podman.podman_container: + name: pulpcore-manager-migrate + image: "{{ pulp_api_image }}" + command: pulpcore-manager migrate --noinput + network: host + secrets: + - 'pulp-settings-py,type=mount,target=/etc/pulp/settings.py' + - 'pulp-symmetric-key,type=mount,target=/etc/pulp/certs/database_fields.symmetric.key' + - name: Start the Pulp API services ansible.builtin.systemd: name: pulp-api enabled: true state: started -- name: Migrate the Pulp database - containers.podman.podman_container_exec: - name: "{{ pulp_api_container_name }}" - command: pulpcore-manager migrate --noinput - - name: Wait for Pulp API service to be accessible ansible.builtin.wait_for: host: "{{ ansible_hostname }}"