How AI is applied across API Evangelist and APIs.io. Read my AI disclosure →
API Evangelist API Evangelist
Discovery
Learnings
Guidance
Toolbox
Alignment
API Evangelist LLC

Best way to avoid local PostgreSQL port conflicts when using Docker Compose with Spring Boot from Eclipse

calendar_today May 29, 2026 person LUIS ANGEL SANTIAGO PALMA domain spring-boot

I am working on a Spring Boot 3 project that can run with different persistence providers: memory, MongoDB, and PostgreSQL. When I run the whole application with Docker Compose, the Spring Boot container connects to PostgreSQL using the Docker service name: SPRING_DATASOURCE_URL: jdbc:postgresql://postgres:5432/ecommerce That works inside Docker. However, during development we usually run the Spring Boot app from Eclipse and only use Docker for the database.

open_in_new Read original post