Commit 4cca13ed authored by Rita Sousa's avatar Rita Sousa

Updated configuration and .yml files to fix deployment on the machine

parent 6ef77af6
FROM bscdataclay/client:dev20210312-alpine
FROM bscdataclay/client:dev20210428-alpine
ENV WORKING_DIR=/demo
ARG DC_SHARED_VOLUME=/srv/dataclay/shared
ARG DEFAULT_NAMESPACE=defaultNS
ARG USER=xavier-rit
ARG DEFAULT_NAMESPACE=ElasticNFR
ARG DEFAULT_USER=NFRtoolUser
ARG DEFAULT_PASS=defaultPass
ARG DEFAULT_STUBS_JAR=/demo/stubs.jar
ARG DEFAULT_STUBS_PATH=/demo/stubs
......@@ -13,11 +13,14 @@ ENV DC_SHARED_VOLUME=${DC_SHARED_VOLUME} \
DATACLAYGLOBALCONFIG=${WORKING_DIR}/global.properties \
DATACLAYSESSIONCONFIG=${WORKING_DIR}/session.properties \
NAMESPACE=${DEFAULT_NAMESPACE} \
USER=${USER} \
USER=${DEFAULT_USER} \
PASS=${DEFAULT_PASS} \
STUBSPATH=${DEFAULT_STUBS_PATH} \
STUBS_JAR=${DEFAULT_STUBS_JAR}
RUN echo ${USER}
RUN echo ${DEFAULT_USER}
RUN echo ${NAMESPACE}
WORKDIR ${WORKING_DIR}
# Install maven:
......
version: '3.5'
services:
dsjava:
image: "bscdataclay/dsjava:dev20210312-alpine"
image: "bscdataclay/dsjava:dev20210428-alpine"
ports:
- "2127:2127"
volumes:
- /opt/dataclay/storage:/dataclay/storage:rw
environment:
- DATASERVICE_HOST=${DATASERVICE_HOST:-192.168.60.68}
- DATASERVICE_HOST=192.168.60.68
- DATASERVICE_NAME=${BACKEND_NAME:-DS2}
- DATASERVICE_JAVA_PORT_TCP=${DSJAVA_PORT:-2127}
- LOGICMODULE_PORT_TCP=${LOGICMODULE_PORT:-11034}
- LOGICMODULE_HOST=${LOGICMODULE_HOST:-192.168.60.28}
- LOGICMODULE_HOST=192.168.60.28
stop_grace_period: 5m
healthcheck:
interval: 5s
......@@ -19,7 +19,7 @@ services:
test: ["CMD-SHELL", "/home/dataclayusr/dataclay/health/health_check.sh"]
dspython:
image: "bscdataclay/dspython:dev20210312-alpine"
image: "bscdataclay/dspython:dev20210428-alpine"
ports:
- "6867:6867"
volumes:
......@@ -27,11 +27,11 @@ services:
depends_on:
- dsjava
environment:
- DATASERVICE_HOST=${DATASERVICE_HOST:-192.168.60.68}
- DATASERVICE_HOST=192.168.60.68
- DATASERVICE_NAME=${BACKEND_NAME:-DS2}
- DATASERVICE_PYTHON_PORT_TCP=${DSPYTHON_PORT:-6867}
- LOGICMODULE_PORT_TCP=${LOGICMODULE_PORT:-11034}
- LOGICMODULE_HOST=${LOGICMODULE_HOST:-192.168.60.28}
- LOGICMODULE_HOST=192.168.60.28
stop_grace_period: 5m
healthcheck:
interval: 5s
......
Subproject commit 108df15f5c95a9dc013e01d02b847a30e3f4a10a
......@@ -17,8 +17,8 @@ services:
build: ./app
environment:
- LOGICMODULE_PORT_TCP=11034
- LOGICMODULE_HOST=${LOGICMODULE_HOST:-192.168.60.28}
- USER=${USER:-NFRtoolUser}
- LOGICMODULE_HOST=192.168.60.28
- USER=NFRtoolUser
- PASS=${PASS:-defaultPass}
- DATASET=${DATASET:-defaultDS}
- NAMESPACE=ElasticNFR
......
version: '3.5'
services:
dcinitializer:
image: "bscdataclay/initializer:dev20210312-alpine"
image: "bscdataclay/initializer:dev20210428-alpine"
depends_on:
- logicmodule
volumes:
......@@ -9,8 +9,8 @@ services:
- /opt/dataclay/model:/model/:rw
environment:
- LOGICMODULE_PORT_TCP=${LOGICMODULE_PORT:-11034}
- LOGICMODULE_HOST=${LOGICMODULE_HOST:-192.168.60.28}
- USER=${USER:-NFRtoolUser}
- LOGICMODULE_HOST=192.168.60.28
- USER=NFRtoolUser
- PASS=${PASS:-defaultPass}
- DATASET=${DATASET:-defaultDS}
- PYTHON_MODELS_PATH=$PYTHON_MODELS_PATH
......@@ -30,14 +30,14 @@ services:
test: [ "CMD-SHELL", "/dataclay-initializer/health_check.sh" ]
logicmodule:
image: "bscdataclay/logicmodule:dev20210312-alpine"
image: "bscdataclay/logicmodule:dev20210428-alpine"
ports:
- "11034:11034"
volumes:
- /opt/dataclay/storage:/dataclay/storage:rw
environment:
- LOGICMODULE_PORT_TCP=${LOGICMODULE_PORT:-11034}
- LOGICMODULE_HOST=${LOGICMODULE_HOST:-192.168.60.28}
- LOGICMODULE_HOST=192.168.60.28
- DATACLAY_ADMIN_USER=admin
- DATACLAY_ADMIN_PASSWORD=admin
- EXPOSED_IP_FOR_CLIENT=$EXPOSED_IP_FOR_CLIENT
......@@ -48,7 +48,7 @@ services:
test: ["CMD-SHELL", "/home/dataclayusr/dataclay/health/health_check.sh"]
dsjava:
image: "bscdataclay/dsjava:dev20210312-alpine"
image: "bscdataclay/dsjava:dev20210428-alpine"
ports:
- "2127:2127"
depends_on:
......@@ -56,11 +56,11 @@ services:
volumes:
- /opt/dataclay/storage:/dataclay/storage:rw
environment:
- DATASERVICE_HOST=${DATASERVICE_HOST:-192.168.60.68}
- DATASERVICE_HOST=192.168.60.68
- DATASERVICE_NAME=${BACKEND_NAME:-DS1}
- DATASERVICE_JAVA_PORT_TCP=${DSJAVA_PORT:-2127}
- LOGICMODULE_PORT_TCP=${LOGICMODULE_PORT:-11034}
- LOGICMODULE_HOST=${LOGICMODULE_HOST:-192.168.60.28}
- LOGICMODULE_HOST=192.168.60.28
stop_grace_period: 5m
healthcheck:
interval: 5s
......@@ -68,7 +68,7 @@ services:
test: ["CMD-SHELL", "/home/dataclayusr/dataclay/health/health_check.sh"]
dspython:
image: "bscdataclay/dspython:dev20210312-alpine"
image: "bscdataclay/dspython:dev20210428-alpine"
ports:
- "6867:6867"
depends_on:
......@@ -77,11 +77,11 @@ services:
volumes:
- /opt/dataclay/storage:/dataclay/storage:rw
environment:
- DATASERVICE_HOST=${DATASERVICE_HOST:-192.168.60.68}
- DATASERVICE_HOST=192.168.60.68
- DATASERVICE_NAME=${BACKEND_NAME:-DS1}
- DATASERVICE_PYTHON_PORT_TCP=${DSPYTHON_PORT:-6867}
- LOGICMODULE_PORT_TCP=${LOGICMODULE_PORT:-11034}
- LOGICMODULE_HOST=${LOGICMODULE_HOST:-192.168.60.28}
- LOGICMODULE_HOST=192.168.60.28
stop_grace_period: 5m
healthcheck:
interval: 5s
......
......@@ -29,7 +29,7 @@ then
fi
# Insert IP address of machine in config files
sed -i -e "s/- DATASERVICE_HOST=.*/- DATASERVICE_HOST=\${DATASERVICE_HOST:-$ip}/" *.yml
sed -i -e "s/- DATASERVICE_HOST=.*/- DATASERVICE_HOST=$ip/" *.yml
if [ $1 != 'LM' ] && [ $1 != 'lm' ]
then
......@@ -54,7 +54,7 @@ StubsClasspath=../dataclay/stubs" | tee ./app/cfgfiles/session.properties > /dev
echo "HOST=$ip
TCPPORT=11034" > ./dataclay/cfgfiles/client.properties
sed -i -e "s/- LOGICMODULE_HOST=.*/- LOGICMODULE_HOST=\${LOGICMODULE_HOST:-$ip}/" *.yml
sed -i -e "s/- LOGICMODULE_HOST=.*/- LOGICMODULE_HOST=$ip/" *.yml
sed -i -e "s/- USER=.*/- USER=\${USER:-$2}/" *.yml
sed -i -e "s/- USER=.*/- USER=$2/" *.yml
#!/bin/sh
bold=$(tput bold)
normal=$(tput sgr0)
if [ $# -ne 1 ]
then
printf "ERROR: Illegal number of parameteres supplied!\nThe Docker image has the following structure -> repository/image_name:tag_name\n"
printf "Write the new ${bold}tag_name${normal} you want to update on .yml files. For example, execute\n$0 dev2021XXXX-alpine\n"
exit 1
fi
echo Updating version to $1 on .yml files
sed -i -e "s@image: \"bscdataclay\/initializer:.*@image: \"bscdataclay\/initializer:$1\"@" *.yml
sed -i -e "s@image: \"bscdataclay\/logicmodule:.*@image: \"bscdataclay\/logicmodule:$1\"@" *.yml
sed -i -e "s@image: \"bscdataclay\/dsjava:.*@image: \"bscdataclay\/dsjava:$1\"@" *.yml
sed -i -e "s@image: \"bscdataclay\/dspython:.*@image: \"bscdataclay\/dspython:$1\"@" *.yml
echo WARNING: Check Dockerfile manually!! The first line should be \"FROM bscdataclay/client:$1\"
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment