mirror of
https://github.com/ansible/awx.git
synced 2026-01-11 10:00:01 -03:30
Run migrations via a task, not in the container
* Issue: https://github.com/ansible/awx/issues/9077 * Fixes problem with migrations not completing
This commit is contained in:
parent
57c3b9ab17
commit
88a0d98447
@ -36,6 +36,11 @@
|
||||
register: awx_secret_key
|
||||
|
||||
- block:
|
||||
- name: Run migrations in task container
|
||||
shell: docker-compose run --rm --service-ports task awx-manage migrate --no-input
|
||||
args:
|
||||
chdir: "{{ docker_compose_dir }}"
|
||||
|
||||
- name: Start the containers
|
||||
docker_compose:
|
||||
project_src: "{{ docker_compose_dir }}"
|
||||
@ -50,6 +55,11 @@
|
||||
command: docker exec awx_task '/usr/bin/update-ca-trust'
|
||||
when: awx_compose_config.changed or awx_compose_start.changed
|
||||
|
||||
- name: Wait for launch script to create user
|
||||
wait_for:
|
||||
timeout: 10
|
||||
delegate_to: localhost
|
||||
|
||||
- name: Create Preload data
|
||||
command: docker exec awx_task bash -c "/usr/bin/awx-manage create_preload_data"
|
||||
when: create_preload_data|bool
|
||||
|
||||
@ -149,6 +149,7 @@ services:
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
environment:
|
||||
AWX_SKIP_MIGRATIONS: "1"
|
||||
http_proxy: {{ http_proxy | default('') }}
|
||||
https_proxy: {{ https_proxy | default('') }}
|
||||
no_proxy: {{ no_proxy | default('') }}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user