summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/install/install-functions14
-rwxr-xr-xscripts/install/install-image24
-rwxr-xr-xscripts/rl-system.init6
3 files changed, 36 insertions, 8 deletions
diff --git a/scripts/install/install-functions b/scripts/install/install-functions
index 3bdc1fde..29707dff 100755
--- a/scripts/install/install-functions
+++ b/scripts/install/install-functions
@@ -43,18 +43,20 @@ VYATTA_CFG_DIR=${vyatta_sysconfdir}/config
# the floppy config dir
FD_CFG_DIR=/media/floppy/config
-# Process ID for progress_indicator
-SPID=$$
-
+# PROGRESS_PID can be exported by top-level script
progress_indicator () {
+ local spid=$PROGRESS_PID
+ if [ -z "$spid" ]; then
+ spid=$$
+ fi
case "$1" in
start)
- $vyatta_bindir/progress-indicator $SPID &
+ $vyatta_bindir/progress-indicator $spid &
;;
*)
- if ! rm /tmp/pi.$SPID 2>/dev/null; then
+ if ! rm /tmp/pi.$spid 2>/dev/null; then
sleep 1
- rm /tmp/pi.$SPID 2>/dev/null
+ rm /tmp/pi.$spid 2>/dev/null
fi
sleep 1
echo -n -e "\b"
diff --git a/scripts/install/install-image b/scripts/install/install-image
index 0bf31a00..6ed0f732 100755
--- a/scripts/install/install-image
+++ b/scripts/install/install-image
@@ -5,6 +5,8 @@ source /opt/vyatta/sbin/install-functions
# export INSTALL_LOG for the scripts invoked
export INSTALL_LOG=/tmp/install-$$.log
+# export PROGRESS_PID for the scripts invoked
+export PROGRESS_PID=$$
# file for get-partition output
PART_FILE=''
@@ -114,12 +116,30 @@ fi
trap sig_handler INT KILL
trap exit_handler EXIT
+cat <<EOF
+Welcome to the Vyatta install program. This script
+will walk you through the process of installing the
+Vyatta image to a local hard drive.
+EOF
+
+response=''
+while [ -z $response ]
+do
+ echo -n "Would you like to continue? (Yes/No) [Yes]: "
+ response=$(get_response "Yes" "Yes No Y N")
+ if [ "$response" == "no" ] || [ "$response" == "n" ]; then
+ fail_exit 'Ok then.'
+ fi
+done
+
if is_live_cd_boot; then
if [ -n "$NEW_ISO" ]; then
- fail_exit 'Do not specify an image when installing from a live CD.'
+ echo 'You are trying to install from a live CD boot. The live CD image'
+ fail_exit 'will be used. Do not specify an ISO image file.'
fi
elif [ -z "$NEW_ISO" ]; then
- fail_exit 'Must specify an image to install.'
+ echo 'You are trying to install from an already installed system. An ISO'
+ fail_exit 'image file to install must be specified.'
else
# installing on an installed system. set up the new image.
set_up_new_iso
diff --git a/scripts/rl-system.init b/scripts/rl-system.init
index 3ca02ed2..2cca5d98 100755
--- a/scripts/rl-system.init
+++ b/scripts/rl-system.init
@@ -169,6 +169,11 @@ setup_ntp_config_file () {
log_failure_msg "NTP template config file doesn\'t exist"
fi
}
+
+# restore PAM back to virgin state (no radius other services)
+pam_reset () {
+ DEBIAN_FRONTEND=noninteractive pam-auth-update unix
+}
start () {
udev_rescan
@@ -182,6 +187,7 @@ start () {
sysctl -q -e -p /opt/vyatta/etc/vyatta-sysctl.conf ||
log_failure_msg "can\'t configure kernel settings"
set_ipv6_params
+ pam_reset
update_version_info
## Clear out apt config file--it will be filled in by rtrmgr