Re-add sudo to CI
This commit is contained in:
parent
7ccd0109d2
commit
6d5e73c87b
@ -31,7 +31,7 @@ build-arm64:
|
|||||||
stage: build
|
stage: build
|
||||||
script:
|
script:
|
||||||
- apt update
|
- apt update
|
||||||
- apt install -y curl xz-utils file
|
- apt install -y curl xz-utils file sudo
|
||||||
- ./arm64-build.sh
|
- ./arm64-build.sh
|
||||||
artifacts:
|
artifacts:
|
||||||
paths:
|
paths:
|
||||||
|
@ -13,10 +13,10 @@ OFFSET_IMG=$(file $RASPIOS_IMG | cut -d';' -f3 | cut -d',' -f8 | cut -d' ' -f3)
|
|||||||
mkdir -p mnt
|
mkdir -p mnt
|
||||||
|
|
||||||
echo "Mounting second partition"
|
echo "Mounting second partition"
|
||||||
mount $RASPIOS_IMG -o offset=$((512*$OFFSET_IMG)) mnt
|
sudo mount $RASPIOS_IMG -o offset=$((512*$OFFSET_IMG)) mnt
|
||||||
|
|
||||||
echo "Chroot into partition to start edition"
|
echo "Chroot into partition to start edition"
|
||||||
chroot mnt /bin/sh <<"EOT"
|
sudo chroot mnt /bin/sh <<"EOT"
|
||||||
|
|
||||||
usermod -l creator pi
|
usermod -l creator pi
|
||||||
usermod -d /home/creator -m creator
|
usermod -d /home/creator -m creator
|
||||||
@ -28,5 +28,5 @@ systemctl enable ssh
|
|||||||
echo "kenoma" > /etc/hostname
|
echo "kenoma" > /etc/hostname
|
||||||
EOT
|
EOT
|
||||||
|
|
||||||
umount mnt
|
sudo umount mnt
|
||||||
xz $RASPIOS_IMG
|
xz $RASPIOS_IMG
|
||||||
|
Loading…
Reference in New Issue
Block a user