Browse Source

chg: [docker-builder] renamed hooks.

postgres
Valentin Lab 10 years ago
parent
commit
995efe92cd
  1. 0
      precise/docker-builder/src/usr/local/bin/hook-docker-build
  2. 7
      precise/docker-builder/src/usr/local/bin/hook-docker-update

0
precise/docker-builder/src/usr/local/bin/docker-build → precise/docker-builder/src/usr/local/bin/hook-docker-build

7
precise/docker-builder/src/usr/local/bin/docker-update → precise/docker-builder/src/usr/local/bin/hook-docker-update

@ -36,11 +36,13 @@ if ! [ -d "$COMPONENT_NAME" ]; then
exit 1
fi
if [ -e "$COMPONENT_NAME.locked" ]; then
lock=$DOCKER_UPDATE_PATH/$COMPONENT_NAME.lock
if [ -e "$lock" ]; then
echo "Master is being updated."
echo "Or '$COMPONENT_NAME.locked' file was left dangling over."
echo "Or '$lock' file was left dangling over."
exit 1
fi
touch "$lock"
clean_all() {
@ -54,7 +56,6 @@ tmpdir="$DOCKER_UPDATE_PATH"/tmp
mkdir -p "$tmpdir"
tmpdir_changes=$(mktemp -d $tmpdir/$COMPONENT_NAME.changes.XXXXXX)
tmpdir_root=$(mktemp -d $tmpdir/$COMPONENT_NAME.root.XXXXXX)
trap "clean_all" EXIT
mount -t aufs -o br=$tmpdir_changes:$DOCKER_UPDATE_PATH/$COMPONENT_NAME -o udba=none none "$tmpdir_root"
cd "$tmpdir_root"
Loading…
Cancel
Save