Make scripts quit on error
This commit is contained in:
parent
60984157c1
commit
03d1593d42
@ -1,4 +1,5 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
set -e
|
||||||
echo $(head -c4 </dev/urandom|xxd -p -u) >"/etc/hostname"
|
echo $(head -c4 </dev/urandom|xxd -p -u) >"/etc/hostname"
|
||||||
echo "$OPUS_SOURCES" >"/etc/apt/sources.list"
|
echo "$OPUS_SOURCES" >"/etc/apt/sources.list"
|
||||||
apt -y update
|
apt -y update
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
set -e
|
||||||
apt -y install firmware-nonfree
|
apt -y install firmware-nonfree
|
||||||
apt -y autoclean
|
apt -y autoclean
|
||||||
rm /setup
|
rm /setup
|
@ -1,4 +1,5 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
set -e
|
||||||
apt -y install cloud-utils
|
apt -y install cloud-utils
|
||||||
apt -y autoclean
|
apt -y autoclean
|
||||||
grub-install --boot-directory="/boot" --modules=part_msdos "${DISK_LOOP}"
|
grub-install --boot-directory="/boot" --modules=part_msdos "${DISK_LOOP}"
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
set -e
|
||||||
alias cp="cp --reflink=auto"
|
alias cp="cp --reflink=auto"
|
||||||
export STAGE_INPUT="$1"
|
export STAGE_INPUT="$1"
|
||||||
export STAGE_OUTPUT="$2"
|
export STAGE_OUTPUT="$2"
|
||||||
|
@ -1,2 +1,3 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
set -e
|
||||||
cp --reflink=auto -a "$1" "$2"
|
cp --reflink=auto -a "$1" "$2"
|
@ -1,3 +1,4 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
set -e
|
||||||
export OPUS_ARCH=amd64
|
export OPUS_ARCH=amd64
|
||||||
export OPUS_LINUX=linux-image-amd64
|
export OPUS_LINUX=linux-image-amd64
|
@ -1,3 +1,4 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
set -e
|
||||||
export OPUS_ARCH=i386
|
export OPUS_ARCH=i386
|
||||||
export OPUS_LINUX=linux-image-686
|
export OPUS_LINUX=linux-image-686
|
@ -1,4 +1,5 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
set -e
|
||||||
export OPUS_SOURCES="deb http://deb.devuan.org/merged $OPUS_DIST main contrib non-free
|
export OPUS_SOURCES="deb http://deb.devuan.org/merged $OPUS_DIST main contrib non-free
|
||||||
# deb-src http://deb.devuan.org/merged $OPUS_DIST main contrib non-free
|
# deb-src http://deb.devuan.org/merged $OPUS_DIST main contrib non-free
|
||||||
|
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
set -e
|
||||||
mount -o bind "/dev" "$1/dev"
|
mount -o bind "/dev" "$1/dev"
|
||||||
mount -o bind "/dev/pts" "$1/dev/pts"
|
mount -o bind "/dev/pts" "$1/dev/pts"
|
||||||
mount -o bind "/sys" "$1/sys"
|
mount -o bind "/sys" "$1/sys"
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
set -e
|
||||||
if [ -d "$1" ]; then
|
if [ -d "$1" ]; then
|
||||||
rm -rf "$1"
|
rm -rf "$1"
|
||||||
fi
|
fi
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
set -e
|
||||||
export DISK_IMAGE="$2"
|
export DISK_IMAGE="$2"
|
||||||
export ROOT_MOUNT="$OPUS_OUTPUT/mount"
|
export ROOT_MOUNT="$OPUS_OUTPUT/mount"
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user