mirror of
https://github.com/EpicMorg/docker-scripts.git
synced 2024-12-28 15:45:44 +03:00
53 lines
1.7 KiB
YAML
53 lines
1.7 KiB
YAML
- name: Read versions from file
|
|
slurp:
|
|
src: "roles/common/files/versions/bitbucket/9.jdk17.txt"
|
|
register: version_output
|
|
|
|
- name: Set version variable
|
|
set_fact:
|
|
bitbucket_versions: "{{ version_output['content'] | b64decode | trim | split('\n') }}"
|
|
|
|
- name: Create directories for Bitbucket versions
|
|
file:
|
|
path: "{{ target_directory_bitbucket_9 }}/{{ item }}"
|
|
state: directory
|
|
mode: '0755'
|
|
force: true
|
|
with_items: "{{ bitbucket_versions }}"
|
|
|
|
- name: Copy .env with link from template to each version directory
|
|
template:
|
|
src: "env/template.bitbucket.4-9.env.j2"
|
|
dest: "{{ target_directory_bitbucket_9 }}/{{ item }}/.env"
|
|
force: true
|
|
with_items: "{{ bitbucket_versions }}"
|
|
|
|
- name: Copy docker-compose.yml from template to each version directory
|
|
template:
|
|
src: "docker-compose/template.docker-compose.jdk17.yml.j2"
|
|
dest: "{{ target_directory_bitbucket_9 }}/{{ item }}/docker-compose.yml"
|
|
force: true
|
|
with_items: "{{ bitbucket_versions }}"
|
|
|
|
- name: Copy Dockerfile.jdk17 from template to each version directory
|
|
template:
|
|
src: "dockerfile/template.Dockerfile.jdk17.j2"
|
|
dest: "{{ target_directory_bitbucket_9 }}/{{ item }}/Dockerfile"
|
|
force: true
|
|
with_items: "{{ bitbucket_versions }}"
|
|
|
|
- name: Copy entrypoint.sh from 'files' directory to each version directory
|
|
copy:
|
|
src: "entrypoint.sh"
|
|
dest: "{{ target_directory_bitbucket_9 }}/{{ item }}/entrypoint.sh"
|
|
mode: "0777"
|
|
force: true
|
|
with_items: "{{ bitbucket_versions }}"
|
|
|
|
- name: Copy Makefile from 'files' directory to each version directory
|
|
copy:
|
|
src: "Makefile"
|
|
dest: "{{ target_directory_bitbucket_9 }}/{{ item }}/Makefile"
|
|
force: true
|
|
with_items: "{{ bitbucket_versions }}"
|