Skip to content

Appserver Postgres Client mismatch #2

Open
@dpacassi

Description

@dpacassi

When creating a Drupal project with Lando and the following yml file:

name: testproject
recipe: drupal9
config:
  webroot: web
  php: '7.4'
  composer_version: '1.10.22'
  xdebug: false
  database: postgres:13

The DB version is 13 while the client bin versions (psql and pg_dump on appserver) are still on version 10.
If I define another Postgres version in the config, I'd expect that the recipe automatically uses the right version also for the client commands (psql, pg_dump).

I guess this is related to lando/lando#1680. I found a workaround also there.
I added following lines to get the client bins with the right version:

    build_as_root:
      - "apt -y update && apt-get install -y gnupg2 && echo 'deb https://apt.postgresql.org/pub/repos/apt/ stretch-pgdg main' >> /etc/apt/sources.list.d/pgdg.list && wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | apt-key add - && apt -y update && apt-get install -y postgresql-client-13"

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions