linkextractor icon indicating copy to clipboard operation
linkextractor copied to clipboard

linkextractor-api should expose port 5000 only inside container,

Open ldelaprade opened this issue 5 years ago • 1 comments

hence replacing 'ports' with 'expose' in docker-compose.yml. This would imply a small change in play-with-docker.github.io/_posts/2018-09-22-microservice-orchestration.markdown as well to explain the nuance. So this should be replace as well:

We should now be able to talk to the API service as before:
curl -i http://localhost:5000/api/http://example.com/

with something like The PHP web server will access the API which is no longer exposed outside the container.

ldelaprade avatar Oct 25 '20 10:10 ldelaprade

Thanks for the PR and your thoughts. However, this was an intentional one to allow the API service be exposed publicly the very same way the PHP application is, so that someone who wants to write their own application, they can use the API endpoint instead.

While making this change will not necessarily make much difference in the lesson, but it will not bring anything new to the table either. So, it will be an extra work of changing the lesson and getting that reviewed, merged, and deployed.

ibnesayeed avatar Oct 25 '20 20:10 ibnesayeed