+# check if we already use an external mirror
+grep -q "external mirror" $target/etc/apt/sources.list && exit 0
+
+cat <<EOM > $target/etc/apt/sources.list
+# external mirror
+deb $ubuntumirror/ubuntu $ubuntudist main universe
+deb $ubuntumirror/ubuntu $ubuntudist-updates main universe
+deb $ubuntumirror/ubuntu $ubuntudist-security main universe
+EOM