summaryrefslogtreecommitdiff
path: root/common/bin/jailgame
diff options
context:
space:
mode:
authorSimon Parri <simonparri@ganzeria.com>2025-07-22 00:56:22 +0200
committerSimon Parri <simonparri@ganzeria.com>2025-07-22 11:49:01 +0200
commitd2c331b9f036951eef062dd5141c75182375ba12 (patch)
tree325bf3c56b70ec845e8de9349f45408ed844e747 /common/bin/jailgame
downloaddotfiles-d2c331b9f036951eef062dd5141c75182375ba12.tar.gz
dotfiles-d2c331b9f036951eef062dd5141c75182375ba12.zip
Add current configuration
Diffstat (limited to 'common/bin/jailgame')
-rwxr-xr-xcommon/bin/jailgame12
1 files changed, 12 insertions, 0 deletions
diff --git a/common/bin/jailgame b/common/bin/jailgame
new file mode 100755
index 0000000..8dbbd1f
--- /dev/null
+++ b/common/bin/jailgame
@@ -0,0 +1,12 @@
+#!/bin/sh
+if ([ "$1" ] && [ "$2" ]); then
+ exe=$2
+ name=$1
+else
+ exe=$1
+ name=$(basename $1)
+fi
+dir="$HOME/games/jail/$name"
+mkdir -p $dir
+
+firejail --name=$name --private=$dir --dbus-system=filter --caps.drop=all --disable-mnt $exe