Skip to content

Commit

Permalink
Merge pull request #30 from cyface-de/release-2.1.5_DAT-1194
Browse files Browse the repository at this point in the history
Release 2.1.5 dat 1194
  • Loading branch information
hb0 authored May 17, 2022
2 parents 4f4463e + 3434ed6 commit 90126c7
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 23 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/publish-docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
# version: 1.0.2
# since: 1.0.0
#
# Version: 2.1.4
# Version: 2.1.5
name: (Test) Publish docker images

on:
Expand All @@ -25,7 +25,7 @@ on:

# Specify JARs version here.
env:
JARS_VERSION: '6.7.0'
JARS_VERSION: '6.8.0'

jobs:
publish:
Expand Down
28 changes: 7 additions & 21 deletions collector/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,9 @@ main() {
loadJwtParameters
loadSaltParameters
loadApiParameters
loadMongoParameters
loadCollectorParameters
loadConfig
waitForDatabase "mongo-data"
waitForDatabase "mongo-user"
waitForDatabase "mongo"
startApi
}

Expand Down Expand Up @@ -78,18 +76,6 @@ loadApiParameters() {
fi
}

loadMongoParameters() {
if [ -z "$MONGO_INITDB_ROOT_USERNAME" ]; then
echo "Unable to find MONGO_INITDB_ROOT_USERNAME. Please set the environment variable to an appropriate value! API will not start!"
exit 1
fi
if [ -z "$MONGO_INITDB_ROOT_PASSWORD" ]; then
echo "Unable to find MONGO_INITDB_ROOT_PASSWORD. Please set the environment variable to an appropriate value! API will not start!"
exit 1
fi
MONGO_USER_CONNECTION_STRING="mongodb://${MONGO_INITDB_ROOT_USERNAME}:${MONGO_INITDB_ROOT_PASSWORD}@mongo-user:27017"
}

loadCollectorParameters() {
# JWT Expiration time
if [ -z $JWT_EXPIRATION_TIME_SECONDS ]; then
Expand Down Expand Up @@ -129,14 +115,14 @@ loadConfig() {
\"jwt.private\":\"$JWT_PRIVATE_KEY_FILE_PATH\",\
\"jwt.public\":\"$JWT_PUBLIC_KEY_FILE_PATH\",\
\"mongo.userdb\":{\
\"db_name\":\"cyface-user\",\
\"connection_string\":\"$MONGO_USER_CONNECTION_STRING\",\
\"data_source_name\":\"cyface-user\"\
\"db_name\":\"cyface\",\
\"connection_string\":\"mongodb://mongo:27017\",\
\"data_source_name\":\"cyface\"\
},\
\"mongo.datadb\":{\
\"db_name\":\"cyface-data\",\
\"connection_string\":\"mongodb://mongo-data:27017\",\
\"data_source_name\":\"cyface-data\"\
\"db_name\":\"cyface\",\
\"connection_string\":\"mongodb://mongo:27017\",\
\"data_source_name\":\"cyface\"\
},\
\"http.port\":$CYFACE_API_PORT,\
\"http.host\":\"$CYFACE_API_HOST\",\
Expand Down

0 comments on commit 90126c7

Please sign in to comment.