Skip to content

Commit 4ac36c5

Browse files
committed
Move ansible_user_dir to group_vars
This commit is one of the steps of replacing common used vars with group_vars to improve overall maintenance of variables in ci-framework Signed-off-by: Amartya Sinha <[email protected]>
1 parent 84c46b6 commit 4ac36c5

File tree

64 files changed

+11
-76
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

64 files changed

+11
-76
lines changed

reproducer-clean.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@
7272
- deepscrub
7373
delegate_to: localhost
7474
ansible.builtin.file:
75-
path: "{{ lookup('env', 'HOME') }}/ci-framework-data/ci-reproducer"
75+
path: "{{ ansible_user_dir }}/ci-framework-data/ci-reproducer"
7676
state: absent
7777

7878
- name: Remove basedir

roles/adoption_osp_deploy/molecule/default/converge.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
cifmw_adoption_osp_deploy_repos: []
1313
cifmw_adoption_source_scenario_path: "."
1414
cifmw_basedir: "{{ playbook_dir }}"
15-
ansible_user_dir: "{{ lookup('env', 'HOME') }}"
1615

1716
tasks:
1817
- name: Gather stack nodes and facts

roles/build_containers/molecule/default/prepare.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818
- name: Prepare
1919
hosts: all
2020
vars:
21-
ansible_user_dir: "{{ lookup('env', 'HOME') }}"
2221
cifmw_basedir: "{{ ansible_user_dir }}/ci-framework-data/"
2322
roles:
2423
- role: test_deps

roles/build_containers/molecule/hotfix/prepare.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818
- name: Prepare
1919
hosts: all
2020
vars:
21-
ansible_user_dir: "{{ lookup('env', 'HOME') }}"
2221
cifmw_basedir: "{{ ansible_user_dir }}/ci-framework-data/"
2322
roles:
2423
- role: test_deps

roles/build_openstack_packages/molecule/default/converge.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818
- name: Converge
1919
hosts: all
2020
vars:
21-
ansible_user_dir: "{{ lookup('env', 'HOME') }}"
2221
cifmw_basedir: "{{ cifmw_project_dir_absolute }}"
2322
cifmw_bop_openstack_release: master
2423
cifmw_bop_dlrn_baseurl: https://trunk.rdoproject.org/centos9-master

roles/build_openstack_packages/molecule/default/prepare.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818
- name: Prepare
1919
hosts: all
2020
vars:
21-
ansible_user_dir: "{{ lookup('env', 'HOME') }}"
2221
cifmw_basedir: "{{ cifmw_project_dir_absolute }}"
2322
roles:
2423
- role: test_deps

roles/cert_manager/tasks/validate_certs.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
- name: Create $HOME/bin dir
1818
ansible.builtin.file:
19-
path: "{{ lookup('env', 'HOME') }}/bin"
19+
path: "{{ ansible_user_dir }}/bin"
2020
state: directory
2121
mode: '0755'
2222

@@ -30,11 +30,11 @@
3030
_arch: "{{ lookup('pipe', 'go env GOARCH') }}"
3131
ansible.builtin.get_url:
3232
url: "https://github.com/cert-manager/cmctl/releases/{{ cifmw_cert_manager_version }}/download/cmctl_{{ _os }}_{{ _arch }}"
33-
dest: "{{ lookup('env', 'HOME') }}/bin/cmctl"
33+
dest: "{{ ansible_user_dir }}/bin/cmctl"
3434
mode: "0755"
3535

3636
- name: Verify cert_manager api
3737
environment:
3838
KUBECONFIG: "{{ cifmw_openshift_kubeconfig }}"
3939
PATH: "{{ cifmw_path }}"
40-
ansible.builtin.command: "{{ lookup('env', 'HOME') }}/bin/cmctl check api --wait=2m"
40+
ansible.builtin.command: "{{ ansible_user_dir }}/bin/cmctl check api --wait=2m"

roles/ci_gen_kustomize_values/molecule/default/prepare.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
vars:
2121
cifmw_ci_gen_kustomize_values_src_dir: >-
2222
{{
23-
(lookup('env', 'HOME'),
23+
(ansible_user_dir,
2424
'ci-framework-data',
2525
'artifacts', 'ci_k8s_snippets') | path_join
2626
}}
Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,2 @@
11
---
2-
ansible_user_dir: "{{ lookup('env', 'HOME') }}"
32
openstack_namespace: openstack

roles/compliance/molecule/default/converge.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,15 +18,13 @@
1818
- name: Converge test of controller tasks
1919
hosts: all
2020
vars:
21-
ansible_user_dir: "{{ lookup('env', 'HOME') }}"
2221
cifmw_compliance_dry_run: true
2322
roles:
2423
- role: "compliance"
2524

2625
- name: Converge test of compute tasks
2726
hosts: all
2827
vars:
29-
ansible_user_dir: "{{ lookup('env', 'HOME') }}"
3028
cifmw_compliance_dry_run: true
3129
roles:
3230
- role: "compliance"

0 commit comments

Comments
 (0)