Skip to content

Instantly share code, notes, and snippets.

@ysdede
Created December 7, 2021 15:34
Show Gist options
  • Save ysdede/ffc139d98113bd311162ee02eb29f883 to your computer and use it in GitHub Desktop.
Save ysdede/ffc139d98113bd311162ee02eb29f883 to your computer and use it in GitHub Desktop.
Postgresql 14 installer for Debian (& WSL2)
#!/bin/bash
sudo apt install -y lsb-core libllvm6.0 libpq5 pgdg-keyring wget --allow-unauthenticated
sudo sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt $(lsb_release -cs)-pgdg main" > /etc/apt/sources.list.d/pgdg.list'
wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add -
sudo apt-get update
sudo apt-get -y install postgresql-14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment