diff options
| author | alex <alex@pdp7.net> | 2024-02-11 10:47:47 +0100 |
|---|---|---|
| committer | alex <alex@pdp7.net> | 2024-02-11 10:47:47 +0100 |
| commit | 1680b57336682e5eb4f2633d0788a24c74093837 (patch) | |
| tree | b665cebdab77080b7b43e8ad19acfc1658727169 /scripts/p7s/zfs.py | |
| parent | baa80b70a8891119b63ccab6f62b6a2548a4bda8 (diff) | |
Add update_zfs command
Diffstat (limited to 'scripts/p7s/zfs.py')
| -rw-r--r-- | scripts/p7s/zfs.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/scripts/p7s/zfs.py b/scripts/p7s/zfs.py new file mode 100644 index 00000000..d51ff17c --- /dev/null +++ b/scripts/p7s/zfs.py @@ -0,0 +1,6 @@ +import subprocess + + +def update_zfs(): + version = subprocess.run(["rpm", "-q", "zfs-dkms", '--queryformat=%{VERSION}'], check=True, stdout=subprocess.PIPE, encoding="utf8").stdout + subprocess.run(["sudo", "dkms", "install", f"zfs/{version}"], check=True) |
