Merge "roles/openafs-client: small overhaul of rpm builds"
This commit is contained in:
commit
2653c922cc
@ -13,11 +13,10 @@
|
||||
shell: |
|
||||
DKMS_MAKE_LOGS=/var/lib/dkms-make-logs
|
||||
mkdir ${DKMS_MAKE_LOGS}
|
||||
# NOTE(ianw) 2023-04-27 This follwoing find may be redundant
|
||||
# now; it does not seem to match anything on centos 9-stream
|
||||
# at least.
|
||||
# pre ~ 9-stream
|
||||
find /var/lib/dkms/ -type d -wholename "*/log" -exec cp -r --parents \{\} ${DKMS_MAKE_LOGS} \;
|
||||
cp /var/lib/dkms/openafs/*/build/make.log ${DKMS_MAKE_LOGS}
|
||||
# >= 9-stream
|
||||
find /var/lib/dkms/ -type d -wholename "*/build" -exec cp -r --parents \{\} ${DKMS_MAKE_LOGS} \;
|
||||
chown zuul:zuul ${DKMS_MAKE_LOGS}
|
||||
become: yes
|
||||
- include_role:
|
||||
|
@ -91,8 +91,14 @@
|
||||
- openafs-client
|
||||
|
||||
- name: Ensure openafs-client service running
|
||||
service:
|
||||
name: openafs-client
|
||||
state: started
|
||||
enabled: yes
|
||||
become: yes
|
||||
block:
|
||||
- name: Start service
|
||||
service:
|
||||
name: openafs-client
|
||||
state: started
|
||||
enabled: yes
|
||||
become: yes
|
||||
rescue:
|
||||
- name: Dump service status
|
||||
command: systemctl status openafs-client.service
|
||||
become: yes
|
||||
|
@ -28,34 +28,38 @@
|
||||
gpgcheck: '{{ openafs_client_yum_repo_gpg_check }}'
|
||||
become: yes
|
||||
|
||||
- name: Install kernel modules CentOS 7
|
||||
yum:
|
||||
name:
|
||||
- kernel-devel
|
||||
- dkms
|
||||
- gcc
|
||||
- dkms-openafs
|
||||
enablerepo: epel # dkms
|
||||
state: present
|
||||
become: yes
|
||||
when: ansible_distribution_version is version('8', '<')
|
||||
|
||||
- name: Install kernel modules CentOS 8
|
||||
- name: Install kernel dev packages
|
||||
dnf:
|
||||
name:
|
||||
- kernel-devel
|
||||
- dkms
|
||||
- gcc
|
||||
- make
|
||||
- dkms
|
||||
enablerepo: epel # dkms
|
||||
state: latest
|
||||
become: yes
|
||||
|
||||
- name: Compare installed headers v running kernel
|
||||
shell: |
|
||||
cur=$(uname -r)
|
||||
rpm=$(rpm -qP kernel-devel | grep uname)
|
||||
if ! echo ${rpm} | grep -q ${cur}; then
|
||||
echo "*** Running kernel does not have headers"
|
||||
echo "cur=${cur}"
|
||||
echo "kernels"
|
||||
rpm -qP kernel-devel | grep uname
|
||||
exit 1
|
||||
else
|
||||
echo "Headers look OK"
|
||||
fi
|
||||
|
||||
- name: Install openafs kernel modules
|
||||
dnf:
|
||||
name:
|
||||
- openafs
|
||||
- openafs-krb5
|
||||
- openafs-client
|
||||
- dkms-openafs
|
||||
enablerepo: epel # dkms
|
||||
state: present
|
||||
become: yes
|
||||
when: ansible_distribution_version is version('8', '>=')
|
||||
|
||||
- name: Install client
|
||||
yum:
|
||||
name:
|
||||
- openafs-krb5
|
||||
- openafs-client
|
||||
state: present
|
||||
become: yes
|
||||
|
Loading…
Reference in New Issue
Block a user