This repository has been archived on 2026-11-04. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
docker-openldap/test/tools/run-container.sh
2014-11-07 15:30:41 +01:00

15 lines
431 B
Bash
Executable File

#!/bin/sh
echo "docker run --name $testContainer $runOptions -d $testImage $runCommand /sbin/my_init --enable-insecure-key"
ID=`docker run --name $testContainer $runOptions -d $testImage $runCommand /sbin/my_init --enable-insecure-key`
sleep 10
echo " --> Obtaining IP"
IP=`docker inspect -f "{{ .NetworkSettings.IPAddress }}" $ID`
if [ "$IP" = "" ]; then
abort "Unable to obtain container IP"
exit 1
else
echo " -->" $IP
fi