modified script to mount '/etc/fstab' entries on boot
This commit is contained in:
parent
ccf9d5046c
commit
e1fc1b19a0
1 changed files with 5 additions and 0 deletions
|
@ -111,6 +111,11 @@ options="defaults,noatime"
|
|||
printf "|> setting up '/var/cache' as tmpfs...\n" && rm -rf "/var/cache/*" &> /dev/null && printf "cache\t/var/cache\ttmpfs\t$options 0 0\n" >> "/etc/fstab"
|
||||
printf "|> setting up '/var/log' as tmpfs...\n" && rm -rf "/var/log/*" &> /dev/null && printf "logs\t/var/log\ttmpfs\t$options 0 0\n" >> "/etc/fstab"
|
||||
printf "|> setting up '/tmp' as tmpfs...\n" && rm -rf "/tmp/*" &> /dev/null && printf "tmp\t/tmp\ttmpfs\t$options,mode=1777 0 0\n" >> "/etc/fstab"
|
||||
printf "|> setting up '/root/.cache' as tmpfs...\n" && rm -rf "/root/.cache/*" &> /dev/null && printf "root-cache\t/root/.cache\ttmpfs\t$options 0 0\n" >> "/etc/fstab"
|
||||
printf "|> setting up '/home/$user/.cache' as tmpfs...\n" && rm -rf "/home/$user/.cache/*" &> /dev/null && printf "user-cache\t/home/$user/.cache\ttmpfs\t$options 0 0\n" >> "/etc/fstab"
|
||||
|
||||
printf "|> modifying '/etc/init.d/localmount'...\n"
|
||||
sed -i 's/keyword -docker -jail -lxc -prefix -systemd-nspawn -vserver/keyword -docker -jail -prefix -systemd-nspawn -vserver/' "/etc/init.d/localmount"
|
||||
|
||||
printf "|> remounting '/etc/fstab' entries...\n"
|
||||
mount -a
|
||||
|
|
Loading…
Reference in a new issue