Skip to content

Commit 61392ed

Browse files
committed
move EESSI CVMFS install and config to nfs export
1 parent a1f71b6 commit 61392ed

File tree

2 files changed

+24
-37
lines changed

2 files changed

+24
-37
lines changed

ansible/roles/compute_init/files/compute-init.yml

Lines changed: 6 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -42,13 +42,6 @@
4242
basic_users_groups: []
4343

4444

45-
cvmfs_quota_limit_mb: 10000
46-
cvmfs_config_default:
47-
CVMFS_CLIENT_PROFILE: single
48-
CVMFS_QUOTA_LIMIT: "{{ cvmfs_quota_limit_mb }}"
49-
cvmfs_config_overrides: {}
50-
cvmfs_config: "{{ cvmfs_config_default | combine(cvmfs_config_overrides) }}"
51-
5245
openhpc_conf_server: "{{ control_node_ip }}"
5346

5447
tasks:
@@ -219,36 +212,13 @@
219212

220213
- name: Configure EESSI
221214
block:
222-
- name: Download Cern GPG key
223-
ansible.builtin.get_url:
224-
url: http://cvmrepo.web.cern.ch/cvmrepo/yum/RPM-GPG-KEY-CernVM
225-
dest: ./cvmfs-key.gpg
226-
227-
- name: Import downloaded GPG key
228-
command: rpm --import cvmfs-key.gpg
229-
230-
- name: Add CVMFS repo
231-
dnf:
232-
name: https://ecsft.cern.ch/dist/cvmfs/cvmfs-release/cvmfs-release-latest.noarch.rpm
233-
234-
- name: Install CVMFS
235-
dnf:
236-
name: cvmfs
237-
238-
- name: Install EESSI CVMFS config
239-
dnf:
240-
name: https://github.com/EESSI/filesystem-layer/releases/download/latest/cvmfs-config-eessi-latest.noarch.rpm
241-
# NOTE: Can't find any docs on obtaining gpg key - maybe downloading directly from github is ok?
242-
disable_gpg_check: true
243-
244-
- name: Add base CVMFS config
245-
community.general.ini_file:
215+
- name: Copy /mnt/cluster/cvmfs/default.local contents to /etc/cvmfs/default.local
216+
copy:
217+
src: /mnt/cluster/cvmfs/default.local
246218
dest: /etc/cvmfs/default.local
247-
section: null
248-
option: "{{ item.key }}"
249-
value: "{{ item.value }}"
250-
no_extra_spaces: true
251-
loop: "{{ cvmfs_config | dict2items }}"
219+
owner: root
220+
group: root
221+
mode: 0644
252222

253223
# NOTE: Not clear how to make this idempotent
254224
- name: Ensure CVMFS config is setup

ansible/roles/compute_init/tasks/main.yml

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@
6969

7070
- name: Ensure nfs /exports/cluster configured
7171
block:
72-
- name: Ensure the /exports/hosts directory exists
72+
- name: Ensure the /exports/cluster directory exists
7373
file:
7474
path: /exports/cluster
7575
state: directory
@@ -92,6 +92,23 @@
9292
dest: "/exports/cluster/manila_share_info.yml"
9393
when: os_manila_mount_share_info is defined
9494

95+
- name: Ensure /exports/cluster/cvmfs directory exists
96+
file:
97+
path: /exports/cluster/cvmfs
98+
state: directory
99+
owner: root
100+
group: root
101+
mode: 0755
102+
103+
- name: Copy EESSI CVMFS config to /exports/cluster
104+
copy:
105+
src: /etc/cvmfs/default.local
106+
dest: /exports/cluster/cvmfs/default.local
107+
owner: root
108+
group: root
109+
mode: 0644
110+
remote_src: true
111+
95112
- name: Write openhpc munge key
96113
copy:
97114
content: "{{ vault_openhpc_mungekey | b64decode }}"

0 commit comments

Comments
 (0)