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

Container service updates #141

Merged
merged 5 commits into from
Oct 11, 2024
Merged
Show file tree
Hide file tree
Changes from 4 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
3 changes: 3 additions & 0 deletions roles/xnat/defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,3 +60,6 @@ xnat_config_logo: /images/logo.png # use the default XNAT logo

# Pipeline engine
xnat_pipeline_engine_enabled: true

# Note that AutoRun is currently required for session archive notifications
xnat_autorun_enabled: false
14 changes: 14 additions & 0 deletions roles/xnat/tasks/configure.yml
Original file line number Diff line number Diff line change
Expand Up @@ -203,3 +203,17 @@
validate_certs: "{{ ssl.validate_certs }}"
status_code: 200, 201, 304
loop: "{{ automation_scripts | default([]) }}"

- name: Enable AutoRun pipeline
ansible.builtin.uri:
url: "{{ web_server.url }}/xapi/pipelines"
user: "{{ xnat_service_admin.username }}"
password: "{{ xnat_service_admin.password }}"
method: POST
body_format: json
body:
autoRunEnabled: true,
tomdoel marked this conversation as resolved.
Show resolved Hide resolved
allowAutoRunProjectOverride: false
validate_certs: "{{ ssl.validate_certs }}"
status_code: 200
when: xnat_autorun_enabled
14 changes: 13 additions & 1 deletion roles/xnat_container_service/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,4 +63,16 @@
vars:
container_registry: "{{ item }}"
loop: "{{ xnat_container_service_hubs | default([]) }}"
when: external_storage_drive is defined

- name: Pull containers
ansible.builtin.uri:
url:
"{{ web_server.url }}/xapi/docker/hubs/{{ item.hub_name }}/pull?image={{
item.image }}&save-commands=true"
user: "{{ xnat_service_admin.username }}"
password: "{{ xnat_service_admin.password }}"
method: POST
body_format: json
validate_certs: "{{ ssl.validate_certs }}"
status_code: 200, 404
loop: "{{ xnat_container_service_images | default([]) }}"