Hi,
in this Guided Exercise it says in section 3.1 to create the times-app container with port 8080 exposed to the host (in bold below):
podman run --name times-app \ --network cities -p 8080:8080 -d \ registry.ocp4.example.com:8443/redhattraining/podman-info-times:v0.1
To my understanding, this exposure is not necessary. Otherwise there is no sense in launcing a new container in the cities network just to run curl to test the times-app (section 3.3 of the exercise) as you could test the same from the host by running
curl -s http://localhost:8080/times/BKK
Wouldn't it make more sense to isolate the times-app container in the cities network and NOT expose it's port to the host ? The cities-app will work the same, even if the times-app is only available on the cities network.
Regards
Marc
Red Hat
Learning Community
A collaborative learning environment, enabling open source skill development.