Skip to content

Instantly share code, notes, and snippets.

Keybase proof

I hereby claim:

  • I am pottedplant on github.
  • I am topfpflanze (https://keybase.io/topfpflanze) on keybase.
  • I have a public key ASARDInAJp7liyNUBQnp70huWW3eTk3uLDhUioNxZgOeUAo

To claim this, I am signing this object:

#!/bin/bash
# static apk: tar xf apk-tools-static-*.apk # http://dl-cdn.alpinelinux.org/alpine/latest-stable/main/x86_64/
# setup alpine folder: apk.static -X http://dl-cdn.alpinelinux.org/alpine/latest-stable/main -U --allow-untrusted --root root --initdb add alpine-base util-linux btrfs-progs bash
# remove all tty\d+ consoles from /etc/inittab (inits will conflict otherwise)
# mk initramfs: (cd root && find . -print0 | cpio --null -ov --format=newc | xz --check=crc32 ) > ./initramfs
# append kernel modules: (cd / && find "./lib/modules/${KERNEL}" -print0 | cpio --null -ov --format=newc | xz --check=crc32 ) >> ./initramfs
function step() {
echo "step: $*"
#!/bin/bash -xe
IFNAME=vei_`date +'%s'`
unshare --mount -- bash -e -c \
"
mount -t tmpfs none /etc/isolation_redirects/net
touch /etc/isolation_redirects/net/ns
unshare --net -- bash -e -c \\
\"
#!/bin/bash -xe
root=$1
unshare --ipc --mount --pid --uts --cgroup --fork -- bash -e -c \
"
mount --rbind /sys \"${root}/sys\"
mount --rbind /dev \"${root}/dev\"
mount -t proc none \"${root}/proc\"
mount -t tmpfs none \"${root}/run\"