blob: d17c6f2dd912fb575c3b50979e4214964232148c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
post_install() {
echo 'Copying existing hosts file to 01-hosts.local'
cp -v etc/hosts etc/hosts.d/01-hosts.local
echo
echo ' :: Changes to /etc/hosts will be lost when hosts-gen is run. Put new'
echo ' :: entries in files in /etc/hosts.d.'
echo
echo ' :: To automatically generate the hosts file whenever hosts.d files'
echo ' :: are added or changed, enable the hosts-gen.path unit:'
echo
echo ' systemctl enable hosts-gen.path'
echo
}
pre_remove() {
echo 'Restoring 01-hosts.local to hosts file'
cp -v etc/hosts.d/01-hosts.local etc/hosts
}
|