2023-08-01 14:28:44 +00:00
|
|
|
#!/bin/bash
|
|
|
|
|
2023-08-01 15:40:45 +00:00
|
|
|
stopcontainer()
|
|
|
|
{
|
|
|
|
echo "removing wg0 interface"
|
|
|
|
wg-quick down /data/wg0.conf
|
|
|
|
echo goodbye
|
|
|
|
exit 0
|
|
|
|
}
|
|
|
|
|
|
|
|
trap stopcontainer SIGINT
|
|
|
|
|
2023-08-01 15:01:01 +00:00
|
|
|
for file in /setup.d/*;
|
|
|
|
do
|
|
|
|
echo "Executing setup file $file";
|
|
|
|
bash -c "$file";
|
|
|
|
done
|
|
|
|
|
2023-08-01 15:40:45 +00:00
|
|
|
wg-quick up /data/wg0.conf
|
|
|
|
|
2023-08-06 11:22:52 +00:00
|
|
|
sleep infinity &
|
|
|
|
wait $!
|