You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
addon-context-linux/base/etc/one-context.d/98-execute-scripts

21 lines
297 B

#!/bin/bash
MOUNT_DIR=/mnt
TMP_DIR=/tmp/one-context-tmp
if [ -z "$INIT_SCRIPTS" ]; then
if [ -f "$MOUNT_DIR/init.sh" ]; then
INIT_SCRIPTS=init.sh
fi
fi
mkdir -p $TMP_DIR
cd $MOUNT_DIR
for f in $INIT_SCRIPTS; do
cp $f $TMP_DIR
chmod +x $TMP_DIR/$f
$TMP_DIR/$f
done