基本上,请按照此处概述的步骤操作:https ://wiki.postgresql.org/wiki/Apt 。
sudo apt-get install curl ca-certificates gnupg
curl https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add -
sudo sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt $(lsb_release -cs)-pgdg main" > /etc/apt/sources.list.d/pgdg.list'
sudo apt-get update
sudo apt-get install pgadmin4
(最后一步的实际命令包括postgresql-11
。我从不这样做,因为我只是想要pgadmin4
并且从未遇到过它正常工作的问题。)
无论如何,这是尝试安装时发生的情况:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package pgadmin4 is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package 'pgadmin4' has no installation candidate
我重做了步骤,结果相同。
我也尝试过执行以下操作,但它需要python3.7
我不会安装。
sudo sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt eoan-pgdg main" > /etc/apt/sources.list.d/pgdg.list'
已验证focal
显示在apt.postgresql.org
:
在那之后有点难为情,不知道该做什么。
建议?