copyparty/bin/bubbleparty.sh
osman 433798a09d Clean up scripts with shellcheck and ruff
This commit includes a variety of different non-destructive fixes and
formatting as recommended by shellcheck and by ruff's check/format.
Fixes include things like double quoting vars to prevent space issues,
variety of line formatting in python files, and removing of unused
imports
2025-08-24 21:48:34 -07:00

20 lines
468 B
Bash
Executable file

#!/bin/sh
# usage: ./bubbleparty.sh ./copyparty-sfx.py ...
bwrap \
--unshare-all \
--ro-bind /usr /usr \
--ro-bind /bin /bin \
--ro-bind /lib /lib \
--ro-bind /etc/resolv.conf /etc/resolv.conf \
--dev-bind /dev /dev \
--dir /tmp \
--dir /var \
--bind "$(pwd)" "$(pwd)" \
--share-net \
--die-with-parent \
--file 11 /etc/passwd \
--file 12 /etc/group \
"$@" \
11< <(getent passwd "$(id -u)" 65534) \
12< <(getent group "$(id -g)" 65534)