Skip to content

Commit

Permalink
Exposing a common port
Browse files Browse the repository at this point in the history
  • Loading branch information
jason-fox committed Aug 9, 2023
1 parent 2227738 commit dbcf2c5
Show file tree
Hide file tree
Showing 7 changed files with 14 additions and 7 deletions.
3 changes: 3 additions & 0 deletions .env
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# Project name
COMPOSE_PROJECT_NAME=fiware
EXPOSED_PORT=1026

# Orion variables
ORION_LD_PORT=1026
Expand All @@ -16,6 +17,8 @@ SCORPIO_VERSION=4.1.1
# Stellio variables
STELLIO_DOCKER_TAG=2.5.2
STELLIO_PORT=8080
STELLIO_TIMESCALE_POSTGIS=14-2.11.1-3.3


# IoT Agent Ultralight Variables
ULTRALIGHT_VERSION=2.2.0-distroless
Expand Down
2 changes: 1 addition & 1 deletion README.ja.md
Original file line number Diff line number Diff line change
Expand Up @@ -402,7 +402,7 @@ git clone https://github.com/FIWARE/tutorials.IoT-Agent.git
cd tutorials.IoT-Agent
git checkout NGSI-LD

./services orion|scorpio
./services [orion|scorpio|stellio]
```

> :information_source: **注:** クリーンアップしてやり直す場合は、次のコマンドを実行してください
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -381,7 +381,7 @@ git clone https://github.com/FIWARE/tutorials.IoT-Agent.git
cd tutorials.IoT-Agent
git checkout NGSI-LD

./services orion|scorpio
./services [orion|scorpio|stellio]
```

> :information_source: **Note:** If you want to clean up and start over again you can do so with the following command:
Expand Down
2 changes: 1 addition & 1 deletion docker-compose/orion-ld.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ services:
networks:
- default
ports:
- "${ORION_LD_PORT}:${ORION_LD_PORT}" # localhost:1026
- ${EXPOSED_PORT:-1026}:${ORION_LD_PORT:-1026}
command: -dbhost mongo-db -logLevel DEBUG -forwarding -experimental
healthcheck:
test: curl --fail -s http://orion:${ORION_LD_PORT}/version || exit 1
Expand Down
2 changes: 1 addition & 1 deletion docker-compose/scorpio-aaio.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ services:
networks:
- default
ports:
- "${SCORPIO_PORT}:9090"
- ${EXPOSED_PORT:-1026}:${SCORPIO_PORT:-9090}
depends_on:
- postgres
- kafka
Expand Down
5 changes: 3 additions & 2 deletions docker-compose/stellio.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ services:
environment:
- SPRING_PROFILES_ACTIVE=docker
ports:
- "${STELLIO_PORT}:8080"
- ${EXPOSED_PORT:-1026}:${STELLIO_PORT:-9090}

search-service:
container_name: stellio-search-service
Expand Down Expand Up @@ -82,7 +82,8 @@ services:
postgres:
labels:
org.fiware: 'tutorial'
image: stellio/stellio-timescale-postgis:14-2.9.1-3.3
image: stellio/stellio-timescale-postgis:${STELLIO_TIMESCALE_POSTGIS}

hostname: postgres
container_name: db-postgres
environment:
Expand Down
5 changes: 4 additions & 1 deletion services
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,7 @@ case "${command}" in
export CONTEXT_BROKER=orion:1026
loadData
waitForIoTAgent
echo -e "\033[1;34m${command}\033[0m is now running and exposed on localhost:${EXPOSED_PORT}"
;;
"scorpio")
export $(cat .env | grep "#" -v)
Expand All @@ -244,6 +245,7 @@ case "${command}" in
export CONTEXT_BROKER=scorpio:9090
loadData
waitForIoTAgent
echo -e "\033[1;34m${command}\033[0m is now running and exposed on localhost:${EXPOSED_PORT}"
;;
"stellio")
export $(cat .env | grep "#" -v)
Expand All @@ -263,14 +265,15 @@ case "${command}" in
export CONTEXT_BROKER=stellio:8080
loadData
waitForIoTAgent
echo -e "\033[1;34m${command}\033[0m is now running and exposed on localhost:${EXPOSED_PORT}"
;;
"stop")
export $(cat .env | grep "#" -v)
stoppingContainers
;;
"start")
export $(cat .env | grep "#" -v)
./services orion $2
./services ${CONTEXT_BROKER:=orion} $2
;;
"create")
export $(cat .env | grep "#" -v)
Expand Down

0 comments on commit dbcf2c5

Please sign in to comment.