Last active
September 2, 2020 08:21
-
-
Save oshinko/23e1d3777b153a14057c54be8102804c to your computer and use it in GitHub Desktop.
Install PostgreSQL 12 from Source Code on Amazon Linux 2
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version=12.4 # ref: https://ftp.postgresql.org/pub/source/ | |
sudo yum groupinstall "Development Tools" -y | |
sudo yum install readline readline-devel -y | |
wget -O - https://ftp.postgresql.org/pub/source/v$version/postgresql-$version.tar.bz2 | tar jxf - | |
cd postgresql-$version | |
# ref: https://www.postgresql.org/docs/12/install-short.html | |
./configure | |
make | |
sudo make install | |
# optional | |
cat << EOF >> $HOME/.bash_profile | |
# PostgreSQL | |
export PATH=$PATH:/usr/local/pgsql/bin | |
EOF | |
# see also: https://gist.github.com/oshinko/ff698fade483ee3711e1ae9a1db81147 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment