Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: secure docker ports #48

Merged
merged 1 commit into from
May 29, 2023
Merged

fix: secure docker ports #48

merged 1 commit into from
May 29, 2023

Conversation

marwanhawari
Copy link
Owner

By default, docker bypasses ufw firewall and any ports you expose in docker-compose are exposed to the outside world. There are many articles about how this has caused vulnerabilities and hacks in the past:

This PR specifies the IP address (127.0.0.1) on which Docker should listen for connections destined to this container. This way the PostgreSQL service and Redis service will only be accessible from the local machine itself.

You can check if the port is open to the world using a website like this: https://www.yougetsignal.com/tools/open-ports/

@marwanhawari marwanhawari merged commit 7dff7a6 into main May 29, 2023
1 check passed
@marwanhawari marwanhawari deleted the fix_docker_ports branch May 29, 2023 08:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant