ok, sorted it out. one of two things happened, either docker got
fussier about correct environment settings on the upgrade, or i
screwed up an edit of the environment file. i prefer to blame
docker rather than myself for obvious reasons...
richard
---- On Mon, 19 Feb 2024 17:00:10 -0500 Richard Welty <rwelty@salesium.com> wrote ---
we're using Postgresql 14 with our Laravel/Php appliction. it is working well
in EC2 and in a Docker image on my Ubuntu 22.04 desktop at work. however,
a while back it stopped working with Docker on my Macbook Air in response
to a major OS upgrade. wondering if anyone knows what i might need to change to fix
this.
the docker image is launching, i can open a terminal in docker-desktop and use psql
to connect to it and poke about with a stick. i can also access it via pgadmin using
localhost with port 5432 as expected.
but when i try to migrate the db schema using Laravel Sail, i get the following error:
SQLSTATE[08006] [7] connection to server at "localhost" (127.0.0.1), port 5432 failed: Connection refused
Is the server running on that host and accepting TCP/IP connections?
connection to server at "localhost" (::1), port 5432 failed: Cannot assign requested address
Is the server running on that host and accepting TCP/IP connections? (SQL: select tablename, concat('"', schemaname, '"."', tablename, '"') as qualifiedname from pg_catalog.pg_tables where schemaname in ('public'))
this suggests that postgresql is not being configured properly for access from the container
containing the web app. i have included the configurations from docker-compose.yml below -
but this is the same docker-compose.yml that is currently working on Ubuntu and was working