mirror of
https://git.launchpad.net/livecd-rootfs
synced 2025-05-12 11:22:09 +00:00
* live-build/auto/build:
- system-image: collect the deivce.tar.gz * live-build/ubuntu-core/hooks/09-move-kernel-to-device-tar.binary: - create a device.tar.gz from the installed kernel/modules and remove it from the rootfs * live-build/ubuntu-core/hooks/10-remove-documentation.binary: - strip documentation * live-build/ubuntu-core/hooks/11-remove-extra-packages.chroot: - remove extra packages like libicu52/libqt that are still on the image because vivid system-image has a dependency on u-d-m which depends on libqt * live-build/ubuntu-core/hooks/12-add-docker-user.chroot: - add a docker user/group into the image (this can go once we have a hook for this)
This commit is contained in:
parent
8af855c26d
commit
a618ff72fe
14
debian/changelog
vendored
14
debian/changelog
vendored
@ -4,6 +4,20 @@ livecd-rootfs (2.267) UNRELEASED; urgency=low
|
|||||||
- system-image: do not install ubuntu-minimal
|
- system-image: do not install ubuntu-minimal
|
||||||
- system-image: install KERNEL_FLAVOURS=virtual on i386/amd64
|
- system-image: install KERNEL_FLAVOURS=virtual on i386/amd64
|
||||||
- system-image: use "--linux-packages=linux-image"
|
- system-image: use "--linux-packages=linux-image"
|
||||||
|
* live-build/auto/build:
|
||||||
|
- system-image: collect the deivce.tar.gz
|
||||||
|
* live-build/ubuntu-core/hooks/09-move-kernel-to-device-tar.binary:
|
||||||
|
- create a device.tar.gz from the installed kernel/modules and
|
||||||
|
remove it from the rootfs
|
||||||
|
* live-build/ubuntu-core/hooks/10-remove-documentation.binary:
|
||||||
|
- strip documentation
|
||||||
|
* live-build/ubuntu-core/hooks/11-remove-extra-packages.chroot:
|
||||||
|
- remove extra packages like libicu52/libqt that are still on the
|
||||||
|
image because vivid system-image has a dependency on u-d-m which
|
||||||
|
depends on libqt
|
||||||
|
* live-build/ubuntu-core/hooks/12-add-docker-user.chroot:
|
||||||
|
- add a docker user/group into the image (this can go once we have
|
||||||
|
a hook for this)
|
||||||
|
|
||||||
-- Michael Vogt <michael.vogt@ubuntu.com> Fri, 14 Nov 2014 08:25:14 +0100
|
-- Michael Vogt <michael.vogt@ubuntu.com> Fri, 14 Nov 2014 08:25:14 +0100
|
||||||
|
|
||||||
|
@ -317,6 +317,16 @@ if [ -e "binary/$INITFS/filesystem.packages-remove" ]; then
|
|||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# ubuntu-core splits kernel stuff into a "device" tarball so at this point
|
||||||
|
# we reset it to "none" as all the work to extract it was done already
|
||||||
|
# in a binary hook
|
||||||
|
if [ "$PROJECT" = "ubuntu-core" ] && [ "$SUBPROJECT" = "system-image" ]; then
|
||||||
|
LB_LINUX_FLAVOURS=none
|
||||||
|
|
||||||
|
# rename to have the right prefix etc
|
||||||
|
mv device.tar.gz "$PREFIX.device.tar.gz"
|
||||||
|
fi
|
||||||
|
|
||||||
for FLAVOUR in $LB_LINUX_FLAVOURS; do
|
for FLAVOUR in $LB_LINUX_FLAVOURS; do
|
||||||
if [ -z "$LB_LINUX_FLAVOURS" ] || [ "$LB_LINUX_FLAVOURS" = "none" ]; then
|
if [ -z "$LB_LINUX_FLAVOURS" ] || [ "$LB_LINUX_FLAVOURS" = "none" ]; then
|
||||||
continue
|
continue
|
||||||
|
@ -0,0 +1,21 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
echo "Moving kernel into device tarball"
|
||||||
|
|
||||||
|
# remove the kernel, its part of the bootimg
|
||||||
|
HERE=$(pwd)
|
||||||
|
(cd binary/boot/filesystem.dir && \
|
||||||
|
tar czf $HERE/device.tar.gz \
|
||||||
|
boot/vmlinu?-* \
|
||||||
|
boot/initrd.img-* \
|
||||||
|
vmlinu? \
|
||||||
|
initrd.img \
|
||||||
|
lib/modules/ )
|
||||||
|
|
||||||
|
rm -f binary/boot/filesystem.dir/boot/vmlinu?-*
|
||||||
|
rm -f binary/boot/filesystem.dir/boot/initrd.img-*
|
||||||
|
rm -f binary/boot/filesystem.dir/initrd.img
|
||||||
|
rm -f binary/boot/filesystem.dir/vmlinu?
|
||||||
|
rm -rf binary/boot/filesystem.dir/lib/modules
|
21
live-build/ubuntu-core/hooks/10-remove-documentation.binary
Normal file
21
live-build/ubuntu-core/hooks/10-remove-documentation.binary
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
#!/bin/sh -x
|
||||||
|
|
||||||
|
echo "I: Remove unneeded files from /usr/share/doc "
|
||||||
|
find binary/boot/filesystem.dir/usr/share/doc -depth -type f ! -name copyright|xargs rm -f || true
|
||||||
|
find binary/boot/filesystem.dir/usr/share/doc -empty|xargs rmdir || true
|
||||||
|
|
||||||
|
echo "I: Remove man/info pages"
|
||||||
|
rm -rf binary/boot/filesystem.dir/usr/share/man \
|
||||||
|
binary/boot/filesystem.dir/usr/share/groff \
|
||||||
|
binary/boot/filesystem.dir/usr/share/info \
|
||||||
|
binary/boot/filesystem.dir/usr/share/lintian \
|
||||||
|
binary/boot/filesystem.dir/usr/share/linda \
|
||||||
|
binary/boot/filesystem.dir/var/cache/man
|
||||||
|
|
||||||
|
|
||||||
|
echo "I: Removing /var/lib/apt/lists/*"
|
||||||
|
find binary/boot/filesystem.dir/var/lib/apt/lists/ -type f | xargs rm -f
|
||||||
|
|
||||||
|
echo "I: Removing /var/cache/apt/*.bin"
|
||||||
|
rm -f binary/boot/filesystem.dir/var/cache/apt/*.bin
|
||||||
|
|
@ -0,0 +1,9 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
# we want a really minimal image
|
||||||
|
apt-get remove -y locales
|
||||||
|
|
||||||
|
# this will also get rid of libqt
|
||||||
|
apt-get remove -y libicu52
|
16
live-build/ubuntu-core/hooks/12-add-docker-user.chroot
Normal file
16
live-build/ubuntu-core/hooks/12-add-docker-user.chroot
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
#!/bin/sh -x
|
||||||
|
|
||||||
|
# FIXME: add click hook for user creation
|
||||||
|
|
||||||
|
USER=docker
|
||||||
|
|
||||||
|
echo "I: creating docker user"
|
||||||
|
|
||||||
|
addgroup --system --quiet $USER
|
||||||
|
adduser --system \
|
||||||
|
--ingroup $USER \
|
||||||
|
--disabled-login \
|
||||||
|
--shell /bin/false \
|
||||||
|
--no-create-home \
|
||||||
|
$USER
|
||||||
|
|
Loading…
x
Reference in New Issue
Block a user