Auto DevOps Postgres Database SSL Error

I enabled Auto DevOps on my repo which contains a Spring Boot app.

Part of the Test stage of the Pipeline spawns up a Postgres database which is nice, but I get the following error:
org.postgresql.util.PSQLException: The server does not support SSL.

I altered both SPRING_DATASOURCE_URL and JDBC_DATABASE_URL as Secret Variables in CI/CD settings to change &sslmode=require to &sslmode=disable on both URLs. SPRING_DATA_SOURCE reflects the secret variable change and this seems to solve the problem, but it’s noteworthy that JDBC_DATABASE_URL is not overridden.

Why does it spawn up an image with Postgres that doesn’t support SSL but enforces it as a URL parameter? Or am I doing something very wrong?


I got the same problem using Auto DevOps and Spring Boot with an H2 in-memory-database.

I believe this should not happen in the automatic config - Any news on it?

1 Like

I have a feeling this is because the JVM build pack overrides it. On Heroku this should always be an SSL connection hence the build pack enforces it. You could clone the build pack change the line in the following link:

Then set this as your default build pack.

Hi @brandonscott, using the suggestion from @mackstar, I create this custom buildpack.

and update on gitlabci the variable


Obs.: This repository is designed for experimentation and will not be updated.

Have the same issue. I’m quite surprised that this isn’t fixed.

I’m using Spring Boot and only added a hint for heroku that my java version is 11.

Should be quite the use case for auto devops.