FIWARE / tutorials.TourGuide-App

:mortar_board: FIWARE Tour Guide Application.
https://fiwaretourguide.readthedocs.io/
MIT License
17 stars 19 forks source link

How to add the container IP address to hosts file to make it reachable on Windows 8 #124

Open kamilwlf opened 8 years ago

kamilwlf commented 8 years ago

instruction is for linux: https://www.fiware.org/devguides/fiware-tour-guide-application-a-tutorial-on-how-to-integrate-the-main-fiware-ges/ I'm working on windows, how to add the container IP address to hosts file to make it reachable on Windows 8?

now my example does not work: curl -s -X GET -H "Accept: application/json" -H "Fiware-Service: devguide" -H "Content /json" 'http://192.168.99.100:1026/v1/contextEntities/Elizalde'

"contextElement" : { "type" : "", "isPattern" : "false", "id" : "Elizalde" }, "statusCode" : { "code" : "404", "reasonPhrase" : "No context element found", "details" : "Entity id: /Elizalde/" }

dmabtrg commented 8 years ago

The hosts file on Windows 8 should be located at C:\Windows\System32\drivers\etc\hosts.

kamilwlf commented 8 years ago

What specifically I have to add to this file?

dmabtrg commented 8 years ago

You should insert one line for each of the containers, using the following format:

<IP address> <container name>

i.e.:

172.17.0.9    tourguide
172.17.0.7    idas
172.17.0.6    cygnus
172.17.0.8    keyrock
172.17.0.5    orion
172.17.0.4    mysql
172.17.0.3    mongodb mongo
172.17.0.2    authzforce

Please note that the IP addresses listed above are just an example. You can get the IP address of a container with the following command:

docker inspect -f "{{ .NetworkSettings.IPAddress }}" <container-name>
kamilwlf commented 8 years ago

thanks, your example works but how to get access to: http://devguide What should I assign to http://devguide/? Which address?

 docker ps
NAMES
tourguide
idas
orion
keyrock
mongodb
authzforce
dmabtrg commented 8 years ago

Sorry for the late reply. Where did you see that url? It should be http://tourguide, not http://devguide.

LukasCH09 commented 7 years ago

@dmabtrg, I'm a bit late too, but I think the confusion comes frome the page https://www.fiware.org/devguides/fiware-tour-guide-application-a-tutorial-on-how-to-integrate-the-main-fiware-ges/, which is in the first post of @kamilwlf .

I ran into the same confusion as it says to access http://devguide, which is wrong.

Is this page maintained by anyone?