mirror of
https://github.com/EpicMorg/docker-scripts.git
synced 2025-01-01 09:35:34 +03:00
46 lines
1.4 KiB
YAML
46 lines
1.4 KiB
YAML
|
- name: Read versions from file
|
||
|
slurp:
|
||
|
src: "roles/common/files/versions/jira/6.jdk7.txt"
|
||
|
register: version_output
|
||
|
|
||
|
- name: Set version variable
|
||
|
set_fact:
|
||
|
jira_versions: "{{ version_output['content'] | b64decode | trim | split('\n') }}"
|
||
|
|
||
|
- name: Create directories for Jira versions
|
||
|
file:
|
||
|
path: "{{ target_directory }}/{{ item }}"
|
||
|
state: directory
|
||
|
mode: '0755'
|
||
|
with_items: "{{ jira_versions }}"
|
||
|
|
||
|
- name: Copy template with link to each version directory
|
||
|
template:
|
||
|
src: "template.env.legacy.j2"
|
||
|
dest: "{{ target_directory }}/{{ item }}/.env"
|
||
|
with_items: "{{ jira_versions }}"
|
||
|
|
||
|
- name: Copy docker-compose.yml from 'files' directory to each version directory
|
||
|
copy:
|
||
|
src: "docker-compose.yml"
|
||
|
dest: "{{ target_directory }}/{{ item }}/docker-compose.yml"
|
||
|
with_items: "{{ jira_versions }}"
|
||
|
|
||
|
- name: Copy Dockerfile from 'files' directory to each version directory
|
||
|
copy:
|
||
|
src: "Dockerfile.jdk7"
|
||
|
dest: "{{ target_directory }}/{{ item }}/Dockerfile"
|
||
|
with_items: "{{ jira_versions }}"
|
||
|
|
||
|
- name: Copy entrypoint.sh from 'files' directory to each version directory
|
||
|
copy:
|
||
|
src: "entrypoint.sh"
|
||
|
dest: "{{ target_directory }}/{{ item }}/entrypoint.sh"
|
||
|
with_items: "{{ jira_versions }}"
|
||
|
|
||
|
- name: Copy Makefile from 'files' directory to each version directory
|
||
|
copy:
|
||
|
src: "Makefile"
|
||
|
dest: "{{ target_directory }}/{{ item }}/Makefile"
|
||
|
with_items: "{{ jira_versions }}"
|