iankelling.org
/
git
/
automated-distro-installer
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
add prom monitoring
[automated-distro-installer]
/
fai
/
config
/
scripts
/
FAIBASE
/
10-misc
diff --git
a/fai/config/scripts/FAIBASE/10-misc
b/fai/config/scripts/FAIBASE/10-misc
index 2df59448f2db1db403237580b54d62e74b96d25e..7a0599dd727e86f54c8a7a775f8616f774e532fd 100755
(executable)
--- a/
fai/config/scripts/FAIBASE/10-misc
+++ b/
fai/config/scripts/FAIBASE/10-misc
@@
-11,15
+11,14
@@
else
cp -f /usr/share/zoneinfo/${TIMEZONE} $target/etc/localtime
fi
cp -f /usr/share/zoneinfo/${TIMEZONE} $target/etc/localtime
fi
+if [ -f $target/etc/hosts.orig ]; then
+ mv $target/etc/hosts.orig $target/etc/hosts
+fi
if [ -n "$IPADDR" ]; then
ifclass DHCPC || ainsl -s /etc/hosts "$IPADDR $HOSTNAME.$DOMAIN $HOSTNAME"
else
ifclass DHCPC && ainsl -s /etc/hosts "127.0.0.1 $HOSTNAME"
fi
if [ -n "$IPADDR" ]; then
ifclass DHCPC || ainsl -s /etc/hosts "$IPADDR $HOSTNAME.$DOMAIN $HOSTNAME"
else
ifclass DHCPC && ainsl -s /etc/hosts "127.0.0.1 $HOSTNAME"
fi
-
-if [ -f $target/etc/hosts.orig ]; then
- mv $target/etc/hosts.orig $target/etc/hosts
-fi
fcopy -iM /etc/hosts /etc/motd
# make /root accessible only by root
fcopy -iM /etc/hosts /etc/motd
# make /root accessible only by root
@@
-28,6
+27,10
@@
chown -c root:root $target/root
# copy default dotfiles for root account
fcopy -ir /root
# copy default dotfiles for root account
fcopy -ir /root
+# use tmpfs for /tmp if not defined in disk_config
+if ! grep -Pq '\s/tmp\s' $target/etc/fstab; then
+ ainsl /etc/fstab "tmpfs /tmp tmpfs nodev,nosuid,size=50%,mode=1777 0 0"
+fi
chmod -c 1777 ${target}/tmp
chown -c 0:0 ${target}/tmp
chmod -c 1777 ${target}/tmp
chown -c 0:0 ${target}/tmp