From ee23b4c2b60cdec66eff7dbe5cd2608f491f124b Mon Sep 17 00:00:00 2001 From: Valentin Vidic Date: Mon, 27 Apr 2009 15:40:21 +0200 Subject: [PATCH] Handle issue and issue.net upgrade. --- files/etc/issue | 2 -- files/etc/issue.expect | 1 + files/etc/issue.net | 1 - files/etc/issue.net.expect | 1 + files/etc/issue.net.restore | 1 + files/etc/issue.restore | 2 ++ src/functions.sh | 4 ++-- 7 files changed, 7 insertions(+), 5 deletions(-) delete mode 100644 files/etc/issue create mode 100644 files/etc/issue.expect delete mode 100644 files/etc/issue.net create mode 100644 files/etc/issue.net.expect create mode 100644 files/etc/issue.net.restore create mode 100644 files/etc/issue.restore diff --git a/files/etc/issue b/files/etc/issue deleted file mode 100644 index 0117bcc..0000000 --- a/files/etc/issue +++ /dev/null @@ -1,2 +0,0 @@ -Debian GNU/Linux 3.1 \n \l - diff --git a/files/etc/issue.expect b/files/etc/issue.expect new file mode 100644 index 0000000..8b848c0 --- /dev/null +++ b/files/etc/issue.expect @@ -0,0 +1 @@ +Debian GNU/Linux 4.0 (CARNet Debian 4.0) \n \l diff --git a/files/etc/issue.net b/files/etc/issue.net deleted file mode 100644 index fb3f9e3..0000000 --- a/files/etc/issue.net +++ /dev/null @@ -1 +0,0 @@ -Debian GNU/Linux 3.1 %h diff --git a/files/etc/issue.net.expect b/files/etc/issue.net.expect new file mode 100644 index 0000000..e0b3930 --- /dev/null +++ b/files/etc/issue.net.expect @@ -0,0 +1 @@ +Debian GNU/Linux 4.0 (CARNet Debian 4.0) %h diff --git a/files/etc/issue.net.restore b/files/etc/issue.net.restore new file mode 100644 index 0000000..ccee04f --- /dev/null +++ b/files/etc/issue.net.restore @@ -0,0 +1 @@ +Debian GNU/Linux 4.0 diff --git a/files/etc/issue.restore b/files/etc/issue.restore new file mode 100644 index 0000000..162c8f5 --- /dev/null +++ b/files/etc/issue.restore @@ -0,0 +1,2 @@ +Debian GNU/Linux 4.0 \n \l + diff --git a/src/functions.sh b/src/functions.sh index 7f8546b..1524f96 100644 --- a/src/functions.sh +++ b/src/functions.sh @@ -786,6 +786,7 @@ restore_configs () { restore_config spamassassin-cn razor 1:2.85-1 /etc/razor/razor-agent.conf restore_config kernel-2.6-cn libpam-modules 1.0.1-5 /etc/security/limits.conf restore_config samba-cn samba-common 2:3.2.5-4lenny2 /etc/samba/smb.conf + restore_config '' base-files 5lenny2 /etc/issue /etc/issue.net # check if monitrc is template based if [ -f /etc/monit/monitrc -a ! -f /etc/monit/monitrc.$backup_ext ]; then @@ -810,8 +811,6 @@ restore_configs () { rm -f $config_new fi -# restore_config base-files 4 /etc/issue /etc/issue.net -# restore_config base-files 4 /etc/issue /etc/issue.net # restore_config login 1:4.0.18.1 /etc/pam.d/login # restore_config mysql-server 5.0.3 /etc/init.d/mysql \ # /etc/logrotate.d/mysql-server \ @@ -1220,6 +1219,7 @@ comment_force_overwrite () { fix_issue () { cat > /etc/issue < /etc/issue.net <