Your containersss vill live in ze pod

This commit is contained in:
Alex D. 2023-06-27 10:33:01 +00:00
parent 3ab67e1bb9
commit 3f8be7368b
Signed by: caskd
GPG Key ID: F92BA85F61F4C173
3 changed files with 38 additions and 0 deletions

12
creators/common.sh Normal file
View File

@ -0,0 +1,12 @@
#!/bin/sh
randmac() {
printf \
'%2.2X:%2.2X:%2.2X:%2.2X:%2.2X:%2.2X\n' \
'242' '0' '0' \
"$(randhextet)" "$(randhextet)" "$(randhextet)"
}
randhextet() {
seq 0 255 | shuf | head -n 1
}

10
creators/nsd.sh Executable file
View File

@ -0,0 +1,10 @@
#!/bin/sh
. "$(dirname $0)"/common.sh
podman container create \
--pod default \
--pull=missing \
--image-volume=tmpfs \
--volume nsd-data:/var/lib/nsd:rw,nodev,noexec,nosuid \
oci-archive:daemons/nsd/oci-archive.tar:redxen.eu/daemons/nsd:latest

16
creators/pod.sh Executable file
View File

@ -0,0 +1,16 @@
#!/bin/sh
. "$(dirname $0)"/common.sh
podman pod create \
--userns=auto \
--dns='2606:4700:4700::1111' \
--dns='2606:4700:4700::1001' \
--dns='2001:4860:4860::8888' \
--dns='2001:4860:4860::8844' \
--dns='1.1.1.1' \
--dns='1.0.0.1' \
--dns='8.8.8.8' \
--dns='8.8.4.4' \
--network=v6chris:mac="$(randmac)" \
default