summaryrefslogtreecommitdiff
path: root/src/scripts/23net.sh
diff options
context:
space:
mode:
Diffstat (limited to 'src/scripts/23net.sh')
-rw-r--r--src/scripts/23net.sh67
1 files changed, 59 insertions, 8 deletions
diff --git a/src/scripts/23net.sh b/src/scripts/23net.sh
index c4169ecdd..02869dd9b 100644
--- a/src/scripts/23net.sh
+++ b/src/scripts/23net.sh
@@ -13,16 +13,23 @@ Net ()
{
if [ ! -f "${LIVE_ROOT}"/.stage/image_binary ]
then
+ # Configure chroot
+ Patch_chroot apply
+ Patch_runlevel apply
+
+ # Configure network
+ Patch_network apply
+
mkdir -p "${LIVE_ROOT}"/binary/casper
cp -r "${LIVE_TEMPLATES}"/common/* "${LIVE_ROOT}"/binary
- for manifest in "${LIVE_ROOT}"/filesystem.manifest*
+ for MANIFEST in "${LIVE_ROOT}"/filesystem.manifest*
do
- mv "${manifest}" "${LIVE_ROOT}"/binary/casper/
+ mv "${MANIFEST}" "${LIVE_ROOT}"/binary/casper/
done
# Installing smbfs
- Chroot_exec "apt-get install --yes smbfs"
+ Chroot_exec "apt-get install --yes --force-yes smbfs"
if [ "${LIVE_ARCHITECTURE}" = "amd64" ] || [ "${LIVE_ARCHITECTURE}" = "i386" ]
then
@@ -40,20 +47,43 @@ EOF
Chroot_exec "update-initramfs -tu"
fi
+ # Remove indices
+ rm -rf "${LIVE_CHROOT}"/var/cache/apt
+ mkdir -p "${LIVE_CHROOT}"/var/cache/apt/archives/partial
+ rm -rf "${LIVE_CHROOT}"/var/lib/apt/lists
+ mkdir -p "${LIVE_CHROOT}"/var/lib/apt/lists/partial
+
# Switching package indices to default
if [ "${LIVE_GENERIC_INDICES}" = "yes" ]
then
Indices default
fi
-
+
+ # Deconfigure network
+ Patch_network deapply
+
+ # Deconfigure chroot
+ Patch_runlevel deapply
+ Patch_chroot deapply
+
# Generating rootfs image
Genrootfs
+ # Configure chroot
+ Patch_chroot apply
+ Patch_runlevel apply
+
+ # Configure network
+ Patch_network apply
+
+ # Remove indices
+ rm -rf "${LIVE_CHROOT}"/var/cache/apt
+ mkdir -p "${LIVE_CHROOT}"/var/cache/apt/archives/partial
+ rm -rf "${LIVE_CHROOT}"/var/lib/apt/lists
+ mkdir -p "${LIVE_CHROOT}"/var/lib/apt/lists/partial
+
# Switching package indices to custom
- if [ "${LIVE_GENERIC_INDICES}" = "yes" ]
- then
- Indices custom
- fi
+ Indices custom
# Installing syslinux
Syslinux net
@@ -64,6 +94,13 @@ EOF
# Installing memtest
Memtest net
+ # Deconfigure network
+ Patch_network deapply
+
+ # Deconfigure chroot
+ Patch_runlevel deapply
+ Patch_chroot deapply
+
# Creating tarball
cd "${LIVE_ROOT}" && \
mv binary "`basename ${LIVE_SERVER_PATH}`" && \
@@ -79,9 +116,23 @@ EOF
if [ ! -f "${LIVE_ROOT}"/.stage/image_source ] && [ "${LIVE_SOURCE}" = "yes" ]
then
+ # Configure chroot
+ Patch_chroot apply
+ Patch_runlevel apply
+
+ # Configure network
+ Patch_network apply
+
# Downloading sources
Sources
+ # Deconfigure network
+ Patch_network deapply
+
+ # Deconfigure chroot
+ Patch_runlevel deapply
+ Patch_chroot deapply
+
# Creating tarball
tar cfz source.tar.gz "${LIVE_ROOT}"/source