30 lines
1.0 KiB
YAML
30 lines
1.0 KiB
YAML
- name: build slurm base docker image
|
|
include_tasks: dockerimage_build.yml
|
|
vars:
|
|
slurm_image_prefix: "{{slurm_base_image_prefix | default('slurm') }}"
|
|
image_name: base
|
|
dockerfile: "{{lookup('file', 'slurm-base.Dockerfile')}}"
|
|
files:
|
|
- dest: entrypoint.sh
|
|
content: "{{ lookup('file', 'entrypoint.sh') }}"
|
|
- dest: entry-munge.sh
|
|
content: "{{ lookup('file', 'entry-munge.sh') }}"
|
|
- dest: docker-init
|
|
content: "{{ lookup('file', 'docker-init') }}"
|
|
- dest: start-scripts/10-munge
|
|
content: "{{ lookup('file', 'start-scripts/10-munge') }}"
|
|
image_args:
|
|
moreusers: >-
|
|
{% for a in slurm_user_accounts | default([]) -%}
|
|
{{a['name']}} {{a['dir']}}{{loop.last | ternary('',',')}}
|
|
{%- endfor %}
|
|
when: not slurm_baseimg_build_chg | default(False)
|
|
|
|
- set_fact:
|
|
slurm_baseimg_build_chg:
|
|
"{{(slurm_baseimg_build_chg | default(False)) or
|
|
slurm_img_build.changed}}"
|
|
|
|
- name: "build slurm base docker image {{image_name}}"
|
|
include_tasks: dockerimage_build.yml
|