mirror of
https://git.launchpad.net/livecd-rootfs
synced 2025-05-07 08:51:50 +00:00
Merge lp:~rbalint/livecd-rootfs -b wsl into ubuntu/master
This commit is contained in:
commit
c8812c7b69
1
debian/control
vendored
1
debian/control
vendored
@ -10,6 +10,7 @@ Package: livecd-rootfs
|
|||||||
Architecture: any
|
Architecture: any
|
||||||
Depends: ${misc:Depends},
|
Depends: ${misc:Depends},
|
||||||
apt-utils,
|
apt-utils,
|
||||||
|
attr,
|
||||||
debootstrap,
|
debootstrap,
|
||||||
distro-info,
|
distro-info,
|
||||||
dosfstools,
|
dosfstools,
|
||||||
|
@ -5,3 +5,4 @@ depends disk-image
|
|||||||
depends qcow2
|
depends qcow2
|
||||||
depends vmdk
|
depends vmdk
|
||||||
depends vagrant
|
depends vagrant
|
||||||
|
depends wsl
|
||||||
|
2
live-build/ubuntu-cpc/hooks.d/base/series/wsl
Normal file
2
live-build/ubuntu-cpc/hooks.d/base/series/wsl
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
depends root-dir
|
||||||
|
base/wsl.binary
|
52
live-build/ubuntu-cpc/hooks.d/base/wsl.binary
Executable file
52
live-build/ubuntu-cpc/hooks.d/base/wsl.binary
Executable file
@ -0,0 +1,52 @@
|
|||||||
|
#!/bin/bash -eux
|
||||||
|
# vi: ts=4 expandtab
|
||||||
|
#
|
||||||
|
# Generate the compressed root directory for WSL
|
||||||
|
|
||||||
|
case ${SUBPROJECT:-} in
|
||||||
|
minimized)
|
||||||
|
echo "Skipping minimized $0 build as WSL systems are designed to be interactive"
|
||||||
|
exit 0
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
case $ARCH in
|
||||||
|
amd64|arm64)
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
echo "WSL root tarballs are not generated for $ARCH."
|
||||||
|
exit 0;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if [ -n "${SUBARCH:-}" ]; then
|
||||||
|
echo "Skipping rootfs build for subarch flavor build"
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
. config/functions
|
||||||
|
|
||||||
|
rootfs_dir=wslroot.dir
|
||||||
|
|
||||||
|
# This is the directory created by create-root-dir.binary
|
||||||
|
cp -a rootfs.dir $rootfs_dir
|
||||||
|
|
||||||
|
setup_mountpoint $rootfs_dir
|
||||||
|
|
||||||
|
env DEBIAN_FRONTEND=noninteractive chroot $rootfs_dir apt-get -y -qq install ubuntu-wsl
|
||||||
|
|
||||||
|
create_manifest $rootfs_dir livecd.ubuntu-cpc.wsl.rootfs.manifest
|
||||||
|
teardown_mountpoint $rootfs_dir
|
||||||
|
|
||||||
|
# remove attributes not supported by WSL's tar
|
||||||
|
if [ -d $rootfs_dir/var/log/journal ]; then
|
||||||
|
setfattr -x system.posix_acl_access $rootfs_dir/var/log/journal
|
||||||
|
setfattr -x system.posix_acl_default $rootfs_dir/var/log/journal
|
||||||
|
fi
|
||||||
|
|
||||||
|
cd $rootfs_dir
|
||||||
|
tar --xattrs --sort=name -czf ../livecd.ubuntu-cpc.wsl.rootfs.tar.gz *
|
||||||
|
cd ..
|
||||||
|
|
||||||
|
rm -rf $rootfs_dir
|
Loading…
x
Reference in New Issue
Block a user