Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
use 127.0.0.1 in with-test-db.sh for colima (bluesky-social#1297)
So, since Docker Desktop has licensing issues, some folks use colima for running containers on their macOS machines (The licensing exempted CLI-only version of Docker only exists on Linux). Unfortunately, colima binds host ports only on the IPv4 localhost address (`127.0.0.1`) while the atproto postgres clients will attempt to connect to the IPv6 localhost address (`::1`) that macOS sets in /etc/hosts. See abiosoft/colima#583 and lima-vm/lima#1330 for the tickets against colima. (Docker Desktop binds to both IPv4 and IPv6 localhost addresses and so doesn't have this issue.) To workaround this silly issue, we can use `localhost` within the docker containers and docker-compose, but need to set the `DB_POSTGRES_URL` env var to use the IPv4 localhost explicitly. (Asking folks to edit /etc/hosts causes other tools to break and will be overridden on each OS upgrade.)
- Loading branch information