mirror of
https://bitbucket.org/atlassian/dc-deployments-automation.git
synced 2025-12-14 08:53:07 -06:00
Merged master into ITPLT-1857-stash-related-changes
This commit is contained in:
@@ -24,7 +24,7 @@ atl_stop_exec_path: "{{ atl_product_installation_current }}/{{ atl_stop_script_m
|
||||
atl_systemd_service_dir_map:
|
||||
amazon: "/usr/lib/systemd/system"
|
||||
ubuntu: "/lib/systemd/system"
|
||||
atl_systemd_service_dir: "{{ atl_systemd_service_dir_map[ansible_distribution|lower] }}"
|
||||
atl_systemd_service_dir: "{{ atl_systemd_service_dir_map[ansible_distribution | lower] }}"
|
||||
|
||||
atl_systemd_service_name: "{{ atl_product_edition }}.service"
|
||||
|
||||
|
||||
@@ -1,19 +1,19 @@
|
||||
---
|
||||
|
||||
- name: Restart Product
|
||||
service:
|
||||
ansible.builtin.service:
|
||||
name: "{{ atl_systemd_service_name }}"
|
||||
state: restarted
|
||||
when:
|
||||
- atl_startup_restart
|
||||
- atl_startup_restart | bool
|
||||
- molecule_yml is not defined
|
||||
no_log: true
|
||||
|
||||
- name: Enable Product
|
||||
service:
|
||||
ansible.builtin.service:
|
||||
name: "{{ atl_systemd_service_name }}"
|
||||
enabled: true
|
||||
when:
|
||||
- atl_startup_enable
|
||||
- atl_startup_enable | bool
|
||||
- molecule_yml is not defined
|
||||
no_log: true
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
|
||||
pre_tasks:
|
||||
- name: Create systemd dir if necessary
|
||||
file:
|
||||
ansible.builtin.file:
|
||||
path: "{{ item }}"
|
||||
state: directory
|
||||
with_items:
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
---
|
||||
dependency:
|
||||
name: galaxy
|
||||
driver:
|
||||
name: docker
|
||||
platforms:
|
||||
@@ -18,6 +16,8 @@ platforms:
|
||||
- nofile:262144:262144
|
||||
provisioner:
|
||||
name: ansible
|
||||
env:
|
||||
ANSIBLE_COLLECTIONS_PATH: "../../"
|
||||
options:
|
||||
skip-tags: runtime_pkg
|
||||
inventory:
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
|
||||
pre_tasks:
|
||||
- name: Create systemd dir if necessary
|
||||
file:
|
||||
ansible.builtin.file:
|
||||
path: "{{ item }}"
|
||||
state: directory
|
||||
with_items:
|
||||
@@ -21,17 +21,17 @@
|
||||
- role: product_startup
|
||||
|
||||
post_tasks:
|
||||
- include_vars: ../../defaults/main.yml
|
||||
- ansible.builtin.include_vars: ../../defaults/main.yml
|
||||
|
||||
# workaround Molecule idempotence check
|
||||
# normal pattern of setting changed_when allows file to be written twice, which takes extra time
|
||||
- name: Check if vars have already been dumped
|
||||
stat:
|
||||
ansible.builtin.stat:
|
||||
path: "{{ ansible_vars_dump_location }}"
|
||||
register: ansible_vars_stat_result
|
||||
|
||||
- name: Dump vars to file for inspection
|
||||
copy:
|
||||
ansible.builtin.copy:
|
||||
content: |
|
||||
{{ vars | to_nice_yaml }}
|
||||
dest: "{{ ansible_vars_dump_location }}"
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
---
|
||||
dependency:
|
||||
name: galaxy
|
||||
driver:
|
||||
name: docker
|
||||
platforms:
|
||||
@@ -18,6 +16,8 @@ platforms:
|
||||
- nofile:262144:262144
|
||||
provisioner:
|
||||
name: ansible
|
||||
env:
|
||||
ANSIBLE_COLLECTIONS_PATH: "../../"
|
||||
options:
|
||||
skip-tags: runtime_pkg
|
||||
inventory:
|
||||
|
||||
@@ -10,17 +10,17 @@
|
||||
ansible_vars_dump_location: "/tmp/ansible-vars.yml"
|
||||
|
||||
tasks:
|
||||
- include_vars: ../../defaults/main.yml
|
||||
- ansible.builtin.include_vars: ../../defaults/main.yml
|
||||
|
||||
# workaround Molecule idempotence check
|
||||
# normal pattern of setting changed_when allows file to be written twice, which takes extra time
|
||||
- name: Check if vars have already been dumped
|
||||
stat:
|
||||
ansible.builtin.stat:
|
||||
path: "{{ ansible_vars_dump_location }}"
|
||||
register: ansible_vars_stat_result
|
||||
|
||||
- name: Dump vars to file for inspection
|
||||
copy:
|
||||
ansible.builtin.copy:
|
||||
content: |
|
||||
{{ vars | to_nice_yaml }}
|
||||
dest: "{{ ansible_vars_dump_location }}"
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
---
|
||||
dependency:
|
||||
name: galaxy
|
||||
driver:
|
||||
name: docker
|
||||
platforms:
|
||||
@@ -19,6 +17,7 @@ platforms:
|
||||
provisioner:
|
||||
name: ansible
|
||||
env:
|
||||
ANSIBLE_COLLECTIONS_PATH: "../../"
|
||||
ATL_STARTUP_RESTART: "false"
|
||||
options:
|
||||
skip-tags: runtime_pkg
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
|
||||
pre_tasks:
|
||||
- name: Create systemd dir if necessary
|
||||
file:
|
||||
ansible.builtin.file:
|
||||
path: "{{ item }}"
|
||||
state: directory
|
||||
with_items:
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
---
|
||||
dependency:
|
||||
name: galaxy
|
||||
driver:
|
||||
name: docker
|
||||
platforms:
|
||||
@@ -18,6 +16,8 @@ platforms:
|
||||
- nofile:262144:262144
|
||||
provisioner:
|
||||
name: ansible
|
||||
env:
|
||||
ANSIBLE_COLLECTIONS_PATH: "../../"
|
||||
options:
|
||||
skip-tags: runtime_pkg
|
||||
inventory:
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
---
|
||||
|
||||
- name: "Install systemd service file"
|
||||
template:
|
||||
ansible.builtin.template:
|
||||
src: "product.service.j2"
|
||||
dest: "{{ atl_systemd_service_dir }}/{{ atl_systemd_service_name }}"
|
||||
owner: root
|
||||
|
||||
Reference in New Issue
Block a user