How Compose automatically creates a network for your services.
Networking is one of the most powerful features of Docker Compose, and it works seamlessly out of the box. When you run `docker-compose up`, Compose automatically creates a dedicated user-defined bridge network for your application stack. This network is typically named based on the directory where your `docker-compose.yml` file is located, followed by `_default`. Every service (and thus, every container) defined in your compose file is attached to this same network. This has a major benefit: all containers within the stack can discover and communicate with each other using their service names as hostnames. For example, if you have a service named `api` and another named `database`, the `api` container can connect to the database simply by using the connection string `postgres://user:pass@database:5432/mydb`. Compose's internal DNS server resolves the hostname `database` to the internal IP address of the `database` container. This automatic networking and service discovery capability is what makes connecting microservices so straightforward with Docker Compose. It abstracts away all the manual network creation and container linking, allowing you to focus on defining your application's services and how they should be configured, confident that they will be able to communicate with each other reliably.