All pastes #731778 Raw Edit

50mirror.ubuntu

public text v1 · immutable
·published 2007-10-10 11:59 UTC
rendered paste body
# Ask if a mirror should be used if the base system can be installed from CD.
if [ -e /cdrom/.disk/base_installable ] || [ "$OVERRIDE_BASE_INSTALLABLE" ]; then
	if search-path choose-mirror; then
		db_input medium apt-setup/use_mirror || [ $? -eq 30 ]
		db_go || exit 10
	else
		warning "choose-mirror is not available; cannot offer network mirror"
		exit 1
	fi

	db_get apt-setup/use_mirror
	if [ "$RET" = false ]; then
		exit 1
	fi

	if db_get cdrom/codename && [ "$RET" ]; then
		db_set mirror/codename $RET
	fi
	if db_get cdrom/suite && [ "$RET" ]; then
		db_set mirror/suite $RET
	fi
	choose-mirror -n # no progress bar
fi