Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Do not run "Check Dashboard SS url" and "Check Dashboard user" when archivematica_src_configure_dashboard is false #276

Merged
merged 1 commit into from
Feb 13, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions tasks/configure.yml
Original file line number Diff line number Diff line change
Expand Up @@ -85,19 +85,21 @@
become: "yes"
command: mysql {{ archivematica_src_am_db_name }} -Ns -e "select * from DashboardSettings where name='storage_service_url'"
register: dashboard_ss_url
when: archivematica_src_configure_dashboard|bool

- debug:
msg: "The pipeline is already configured: The dashboard superuser will not be created and the pipeline will not be registered."
when: dashboard_ss_url.stdout != "" and archivematica_src_configure_dashboard|bool
when: archivematica_src_configure_dashboard|bool and dashboard_ss_url.stdout != ""

- name: Check Dashboard user
become: "yes"
command: mysql {{ archivematica_src_am_db_name }} -Ns -e "select * from auth_user where username='{{ archivematica_src_configure_am_user }}'"
register: dashboard_user
when: archivematica_src_configure_dashboard|bool

- debug:
msg: "The dashboard user {{ archivematica_src_configure_am_user }} is already configured: The dashboard superuser will not be created and the pipeline will not be registered."
when: dashboard_user.stdout != "" and archivematica_src_configure_dashboard|bool
when: archivematica_src_configure_dashboard|bool and dashboard_user.stdout != ""

# Create api-key if not defined
- set_fact: archivematica_src_configure_am_api_key={{ 999999999999999999998 | random | to_uuid | hash('md5') }}
Expand Down