diff options
Diffstat (limited to 'scripts')
| -rwxr-xr-x | scripts/live | 5 | ||||
| -rwxr-xr-x | scripts/live-bottom/99hook | 39 |
2 files changed, 44 insertions, 0 deletions
diff --git a/scripts/live b/scripts/live index 0280edd..ea770f4 100755 --- a/scripts/live +++ b/scripts/live @@ -60,6 +60,11 @@ Arguments () export FETCH ;; + hook=*) + HOOK="${ARGUMENT#hook=}" + export HOOK + ;; + hostname=*) HOSTNAME="${ARGUMENT#hostname=}" LIVECONF="changed" diff --git a/scripts/live-bottom/99hook b/scripts/live-bottom/99hook new file mode 100755 index 0000000..0341026 --- /dev/null +++ b/scripts/live-bottom/99hook @@ -0,0 +1,39 @@ +#!/bin/sh + +#set -e + +# initramfs-tools header + +PREREQ="" + +prereqs() +{ + echo "${PREREQ}" +} + +case "${1}" in + prereqs) + prereqs + exit 0 + ;; +esac + +# live-initramfs header + +if [ -z "${HOOK}" ] +then + exit 0 +fi + +. /scripts/live-functions + +log_begin_msg "Executing custom hook script..." + +# live-initramfs script + +cd /root +wget "${HOOK}" + +./$(basename ${HOOK}) + +log_end_msg |
