Small tweaks to the hack scripts to make them simpler
Please do with this as you please (including rebasing and/or squashing it), especially under clause (c) of the DCO. Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
This commit is contained in:
parent
6db32fdefd
commit
3fb1fc0b7b
2 changed files with 8 additions and 16 deletions
|
@ -11,5 +11,6 @@ go build \
|
|||
" \
|
||||
./docker
|
||||
echo "Created binary: $DEST/docker-$VERSION"
|
||||
ln -sf "docker-$VERSION" "$DEST/docker"
|
||||
|
||||
hash_files "$DEST/docker-$VERSION"
|
||||
|
|
|
@ -1,37 +1,28 @@
|
|||
#!/bin/bash
|
||||
|
||||
DEST=$1
|
||||
DOCKERBIN=$DEST/../binary/docker-$VERSION
|
||||
DYNDOCKERBIN=$DEST/../dynbinary/docker-$VERSION
|
||||
DOCKERINITBIN=$DEST/../dynbinary/dockerinit-$VERSION
|
||||
|
||||
set -e
|
||||
|
||||
# subshell so that we can export PATH without breaking other things
|
||||
(
|
||||
export PATH="$DEST/../binary:$DEST/../dynbinary:$PATH"
|
||||
|
||||
bundle_test_integration_cli() {
|
||||
go_test_dir ./integration-cli
|
||||
}
|
||||
|
||||
if [ -x "/usr/bin/docker" ]; then
|
||||
echo "docker found at /usr/bin/docker"
|
||||
elif [ -x "$DOCKERBIN" ]; then
|
||||
ln -s $DOCKERBIN /usr/bin/docker
|
||||
elif [ -x "$DYNDOCKERBIN" ]; then
|
||||
ln -s $DYNDOCKERBIN /usr/bin/docker
|
||||
ln -s $DOCKERINITBIN /usr/bin/dockerinit
|
||||
else
|
||||
if ! command -v docker &> /dev/null; then
|
||||
echo >&2 'error: binary or dynbinary must be run before test-integration-cli'
|
||||
false
|
||||
fi
|
||||
|
||||
|
||||
docker -d -D -p $DEST/docker.pid &> $DEST/docker.log &
|
||||
sleep 2
|
||||
docker info
|
||||
DOCKERD_PID=`cat $DEST/docker.pid`
|
||||
|
||||
bundle_test_integration_cli 2>&1 \
|
||||
| tee $DEST/test.log
|
||||
|
||||
DOCKERD_PID=$(cat $DEST/docker.pid)
|
||||
kill $DOCKERD_PID
|
||||
wait $DOCKERD_PID
|
||||
|
||||
)
|
||||
|
|
Loading…
Add table
Reference in a new issue