Skip to content

Commit

Permalink
Merge pull request #230 from mariux64/add-gpu-policy
Browse files Browse the repository at this point in the history
Add mxq gpu-policy
  • Loading branch information
donald authored Feb 16, 2022
2 parents 0096e6a + aa1a703 commit e4fc72a
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
1 change: 1 addition & 0 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,7 @@ install_data slowio/slowio.slice "$DESTDIR$systemdunitd
install_exec slowio/slowio-mem-control "$DESTDIR$sysconfdir/systemd/system-generators/slowio-mem-control"
install_exec slowio/slowio "$DESTDIR$usr_sbindir/slowio"
install_data misc_systemd_units/fix-lpp.service "$DESTDIR$systemdunitdir/fix-lpp.service"
install_exec misc_etc_files/mxq/gpu-policy "$DESTIDIR$sysconfdir/mxq/gpu-policy"

postinstall
exit
19 changes: 19 additions & 0 deletions misc_etc_files/mxq/gpu-policy
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
#! /bin/bash

hostname="$(hostname -s)"

case "$hostname" in
theredqueen)
policy=a100-split-7
;;
beebee-ate)
policy=phys-gpus
;;
esac

if [ -n "$policy" ]; then
echo "$policy"
else
echo "$0: no GPU policy defined for $hostname" >&2
exit 1
fi

0 comments on commit e4fc72a

Please sign in to comment.