Commit b645f66
committed
fix: [#277] remove public MySQL port exposure for security
MySQL port 3306 was publicly accessible from outside the VM, allowing
anyone on the network to connect to the database. This posed a security
risk as the database credentials could be brute-forced.
Changes:
- Removed ports: - "3306:3306" from MySQL service in docker-compose
- Added security comment explaining why port is not exposed
- Updated unit test to verify port is NOT exposed
MySQL remains accessible to the Tracker via Docker's internal
database_network, and the healthcheck still works because mysqladmin
ping runs inside the container.
Closes #2771 parent 91d2be5 commit b645f66
2 files changed
Lines changed: 8 additions & 5 deletions
File tree
- src/infrastructure/templating/docker_compose/template/renderer
- templates/docker-compose
Lines changed: 3 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
301 | 301 | | |
302 | 302 | | |
303 | 303 | | |
304 | | - | |
| 304 | + | |
305 | 305 | | |
306 | | - | |
307 | | - | |
| 306 | + | |
| 307 | + | |
308 | 308 | | |
309 | 309 | | |
310 | 310 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
176 | 176 | | |
177 | 177 | | |
178 | 178 | | |
179 | | - | |
180 | | - | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
181 | 184 | | |
182 | 185 | | |
183 | 186 | | |
| |||
0 commit comments