diff options
author | John Estabrook <jestabro@vyos.io> | 2020-03-18 17:19:32 -0500 |
---|---|---|
committer | John Estabrook <jestabro@vyos.io> | 2020-03-19 21:25:55 -0500 |
commit | 328ac83dc2c3cb3777ad1ad489dbbe5f74fa6cb3 (patch) | |
tree | 667a9044e51a1b3644d7d1a43a3164e81c75e131 /scripts | |
parent | 7d7298661c18a3c33fd0fad56e9800f7ea2a6fe8 (diff) | |
download | vyos-build-328ac83dc2c3cb3777ad1ad489dbbe5f74fa6cb3.tar.gz vyos-build-328ac83dc2c3cb3777ad1ad489dbbe5f74fa6cb3.zip |
vyos-build: T2142: Add required packages and step for "make GCE"
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/build-GCE-image | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/scripts/build-GCE-image b/scripts/build-GCE-image index 9986e8dc..90eb6468 100755 --- a/scripts/build-GCE-image +++ b/scripts/build-GCE-image @@ -16,6 +16,9 @@ # Purpose: # Build VyOS image for Google cloud. +apt-get update && apt-get install -y \ + grub-pc grub2-common parted kpartx + lb bootstrap lb chroot @@ -60,6 +63,12 @@ OUTPUTGZ=VyOS-"$dateymd".tar.gz IMAGE_SIZE=10 qemu-img create -f raw ${OUTPUT} ${IMAGE_SIZE}G +LOOPNAME=`losetup -f` +LOOPMINOR=${LOOPNAME//[^0-9]} +if [ ! -e $LOOPNAME ]; then + mknod $LOOPNAME b 7 $LOOPMINOR +fi + ${PARTED} -s ${OUTPUT} mktable msdos ${PARTED} -s -a optimal ${OUTPUT} mkpart primary ext4 1Mi 100% ${PARTED} -s ${OUTPUT} set 1 boot on |