Skip to content

Commit

Permalink
Merge pull request #105 from ublue-os/zfs-depmod
Browse files Browse the repository at this point in the history
fix: run depmod after installing ZFS RPMs
  • Loading branch information
bsherman authored Dec 20, 2023
2 parents 3adfd6c + f957633 commit e56ae7c
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 2 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ A generic [Fedora CoreOS image](https://quay.io/repository/fedora/fedora-coreos?
- [nvidia-container-toolkit](https://docs.nvidia.com/datacenter/cloud-native/container-toolkit/latest/sample-workload.html) - latest toolkit which supports both root and rootless podman containers and CDI
- [nvidia container selinux policy](https://github.com/NVIDIA/dgx-selinux/tree/master/src/nvidia-container-selinux) - allows using `--security-opt label=type:nvidia_container_t` for some jobs (some will still need `--security-opt label=disable` as suggested by nvidia)
- [ZFS versions](#tag-matrix) add:
- [ZFS driver](https://github.com/ublue-os/ucore-kmods) - latest driver (currently pinned to 2.1.x series)
- [ZFS driver](https://github.com/ublue-os/ucore-kmods) - latest driver (currently pinned to 2.2.x series)

*NOTE: currently, zincati fails to start on systems with OCI based deployments (like uCore). Upstream efforts are active to correct this.*

Expand All @@ -48,7 +48,7 @@ Suitable for running containerized workloads on either baremetal or virtual mach
- [nvidia container selinux policy](https://github.com/NVIDIA/dgx-selinux/tree/master/src/nvidia-container-selinux) - allows using `--security-opt label=type:nvidia_container_t` for some jobs (some will still need `--security-opt label=disable` as suggested by nvidia)
- Optional [ZFS versions](#tag-matrix) add:
- [sanoid/syncoid dependencies](https://github.com/jimsalterjrs/sanoid) - [see below](#zfs) for details
- [ZFS driver](https://github.com/ublue-os/ucore-kmods) - latest driver (currently pinned to 2.1.x series)
- [ZFS driver](https://github.com/ublue-os/ucore-kmods) - latest driver (currently pinned to 2.2.x series)
- Enables staging of automatic system updates via rpm-ostreed
- Enables password based SSH auth (required for locally running cockpit web interface)
- Disables Zincati auto upgrade/reboot service
Expand Down
3 changes: 3 additions & 0 deletions fedora-coreos/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
set -ouex pipefail

RELEASE="$(rpm -E %fedora)"
KERNEL="$(rpm -q kernel --queryformat '%{VERSION}-%{RELEASE}.%{ARCH}')"

#### PREPARE
# enable testing repos if not enabled on testing stream
Expand All @@ -25,6 +26,8 @@ find /tmp/rpms/
## CONDITIONAL: install ZFS (and sanoid deps)
if [[ "-zfs" == "${ZFS_TAG}" ]]; then
rpm-ostree install pv /tmp/rpms/zfs/*.rpm
# for some reason depmod ran automatically with zfs 2.1 but not with 2.2
depmod -A ${KERNEL}
fi

## CONDITIONAL: install NVIDIA
Expand Down
4 changes: 4 additions & 0 deletions main/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

set -ouex pipefail

KERNEL="$(rpm -q kernel --queryformat '%{VERSION}-%{RELEASE}.%{ARCH}')"
RELEASE="$(rpm -E %fedora)"

#### PREPARE
Expand All @@ -22,6 +23,7 @@ sed -i 's@enabled=1@enabled=0@g' /etc/yum.repos.d/fedora-cisco-openh264.repo
# inspect to see what RPMS we copied in
find /tmp/rpms/


## CONDITIONAL: install ZFS (and sanoid deps)
if [[ "-zfs" == "${ZFS_TAG}" ]]; then
rpm-ostree install /tmp/rpms/zfs/*.rpm \
Expand All @@ -32,6 +34,8 @@ if [[ "-zfs" == "${ZFS_TAG}" ]]; then
perl-Config-IniFiles \
perl-Getopt-Long \
pv
# for some reason depmod ran automatically with zfs 2.1 but not with 2.2
depmod -A ${KERNEL}
fi

## CONDITIONAL: install NVIDIA
Expand Down

0 comments on commit e56ae7c

Please sign in to comment.