Commit cfe79f15 authored by Federico Sismondi's avatar Federico Sismondi

Updated doc with more scripts execution examples

parent 5b98ae9a
......@@ -109,11 +109,85 @@ UPDATE|
# Demo steps
## Put platform up
`docker-compose up -d`
```bash
cd naiades-platform-poc
docker-compose up -d
```
## Check services' status
```bash
>>> docker-compose ps
Name Command State Ports
-------------------------------------------------------------------------------------------------------------------------
db-mongo docker-entrypoint.sh --bin ... Up 0.0.0.0:27017->27017/tcp
db-mysql docker-entrypoint.sh mysqld Up 3306/tcp, 33060/tcp, 0.0.0.0:3307->3307/tcp
fiware-keyrock /opt/fiware-idm/docker-ent ... Up (health: starting) 3000/tcp, 0.0.0.0:3005->3005/tcp
fiware-orion /usr/bin/contextBroker -fg ... Up (health: starting) 0.0.0.0:1026->1026/tcp
fiware-orion-proxy /opt/fiware-pep-proxy/dock ... Up (health: starting) 0.0.0.0:1027->1027/tcp
mock-wms-consumer /opt/mockserver/run_mockse ... Up 1080/tcp, 0.0.0.0:1080->8080/tcp
mongo-express tini -- /docker-entrypoint ... Up 0.0.0.0:8081->3307/tcp, 8081/tcp
```
## Run demo using shell scripts in `scripts` folder
Let's start by looking at the type of REST requests used in the scripts:
```bash
cat 01_create_entity.sh
curl --location --request POST 'http://localhost:1026/v2/entities/' \
--header 'Content-Type: application/json' \
--data-raw '{
"id": "urn:ngsi-ld:FlowerBed:FlowerBed-345",
"type": "FlowerBed",
"category": {
"type": "Property",
"value": ["urbanTreeSpot"]
},
"soilMoistureVwc": {
"type": "Property",
"value": 0.85
},
"dateLastWatering": {
"type": "DateTime",
"value": "2020-02-11T08:00:00Z"
},
"soilTemperature": {
"type": "Property",
"value": 17
},
"address": {
"type": "Property",
"value": {
"addressCountry": "Switzerland",
"streetAddress": "Place de Sardaigne",
"adressLocality": "Carouge",
"type": "PostalAddress"
}
},
"location": {
"type": "GeoProperty",
"value": {
"type": "Point",
"coordinates": [46.184255,6.1378375]
}
}
}'
```
Now, let's run the script:
```bash
cd scripts
./01_create_entity.sh
```
## Put platform down
``` bash
cd naiades-platform-poc
docker-compose down
```
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