See build failures at https://travis-ci.org/dvarrazzo/pgmp/jobs/643995581
$ travis_setup_postgresql 11
Starting PostgreSQL v11
Assertion failed on job for postgresql@11-main.service.
sudo systemctl start postgresql@11-main
See build failures at https://travis-ci.org/dvarrazzo/pgmp/jobs/643995581
$ travis_setup_postgresql 11
Starting PostgreSQL v11
Assertion failed on job for postgresql@11-main.service.
sudo systemctl start postgresql@11-main
The .travis.yml
file that configured the build is
https://github.com/dvarrazzo/pgmp/blob/6e5e612ee428232a5ca30cb3d79a768e7145df43/.travis.yml:
matrix:
include:
# ...
- addons:
postgresql: '11'
apt:
packages:
- postgresql-client-11
- postgresql-server-dev-11
# ...
Looks like we are not installing all the packages required to start the PostgreSQL 11 service.
Oh, sorry, it is your configuration.
Our documentation
advises you to have this:
addons:
postgresql: "11"
apt:
packages:
- postgresql-11
- postgresql-client-11
which indeed works.
Please try that.
It worked indeed, with the addition of the port too: thank you for your help
https://travis-ci.org/dvarrazzo/pgmp/builds/644507910
Isn’t it curious that PG 11 and 12 need such a different configuration from all the other available servers, 9.4-10 (other packages needed, non-standard port)? Here is the config file:
I’m writing from memory, but that is most likely due to the base image not containing these newer versions.
I thought about this a little more, but maybe the addon should be smarter about what packages to install for various versions of PostgreSQL.
I can only give you the PoV of the end user, I don’t know what is in the base image and how difficult is to extend. I suppose if someone asks for a PG 11 service, they expect at least the server and the client packages to be installed (I had already discovered I had to specify to install the postgres-client-NN
packages because I had a "psql
not found" error in the first build attempts, but the “assert failed” at service start because the server package is missing is quite the obscure behaviour).