refactor: setup-server.sh

This commit is contained in:
Strix 2023-10-20 15:44:39 +02:00
parent ac6b592d7f
commit ab9970715a
No known key found for this signature in database
GPG key ID: 49B2E37B8915B774
8 changed files with 17 additions and 14 deletions

View file

@ -0,0 +1,6 @@
#!/bin/sh
if ! [ -f "/etc/ixvd/version" ]; then
echo "applying overlay..."
cp -r skel/. /
fi

View file

@ -22,7 +22,15 @@ fi
set -e set -e
for s in tools/setup/*; do if [ -d "servers/$HOSTNAME/setup.d" ]; then
echo "running server specific setup scripts..."
for s in servers/$HOSTNAME/setup.d/*; do
echo "running $s..."
sh $s
done
fi
for s in tools/server-setup.d/*; do
echo "running $s..." echo "running $s..."
sh $s sh $s
done done

View file

@ -1,11 +0,0 @@
#!/bin/sh
if ! [ -f "/etc/ixvd/version" ]; then
echo "applying overlay..."
cp -r skel/. /
fi
if [ -d "servers/$HOSTNAME/skel" ]; then
echo "applying server specific skeleton..."
cp -r servers/$HOSTNAME/skel/. /
fi