Skip to content

Commit cf17558

Browse files
committed
Resolve issue #12
1 parent ca09a0c commit cf17558

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

02-run.sh

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,12 @@ BASE_DIR=$(pwd -P)
99
DB_VERSION=${DB_VERSION:-18.4.0}
1010
DB_EDITION=$(echo ${DB_EDITION:-xe} | tr '[:upper:]' '[:lower:]')
1111
HOST_DATA_DIR=${CONTAINER_NAME}-oradata
12+
DOCKER_NETWORK_NAME=${DOCKER_NETWORK_NAME:-bridge}
13+
14+
echo "##### Check if Docker network $DOCKER_NETWORK_NAME #####"
15+
docker network inspect -f {{.Name}} $DOCKER_NETWORK_NAME || \
16+
echo "##### Create Docker network $DOCKER_NETWORK_NAME #####"; \
17+
docker network create $DOCKER_NETWORK_NAME
1218

1319
echo "##### Removing any previous containers #####"
1420
docker rm -vf $CONTAINER_NAME
@@ -22,6 +28,7 @@ sudo -n chown 54321:543321 ${HOST_DATA_DIR} || chmod 777 ${HOST_DATA_DIR}
2228

2329
echo "##### Creating container $CONTAINER_NAME #####"
2430
docker run -d --name $CONTAINER_NAME \
31+
--network ${DOCKER_NETWORK_NAME} \
2532
-p ${DOCKER_ORDS_PORT:-50080}:8080 \
2633
-p ${DOCKER_EM_PORT:-55500}:5500 \
2734
-p ${DOCKER_DB_PORT:-51521}:1521 \

0 commit comments

Comments
 (0)