One way to install pgadmin4 is to download its Python wheel at https://www.postgresql.org/ftp/pgadmin3/pgadmin4/v1.0-beta1/pip/ and then use pip to install it:

it is better to install with virtualenv

virtualevn pgadmin_install
cd pgadmin_install
source ./bin/activate
pip install <name of the pgadmin wheel download from https://www.pgadmin.org/download/pgadmin-4-python-wheel/>

According to https://www.pgadmin.org/download/pip4.php, to run pgadmin4, do the following:

and add following code in your config_local.py which is in the same location with config.py, if you install it with virtualenv, the config_local.py should locate in ~/pgadmin4/lib/python2.7/site-packages/pgadmin4

import os
DATA_DIR = os.path.realpath(os.path.expanduser(u'~/.pgadmin/'))
LOG_FILE = os.path.join(DATA_DIR, 'pgadmin4.log')
SQLITE_PATH = os.path.join(DATA_DIR, 'pgadmin4.db')
SESSION_DB_PATH = os.path.join(DATA_DIR, 'sessions')
STORAGE_DIR = os.path.join(DATA_DIR, 'storage')

Once installed, you will need to create a config_local.py file in the same directory as config.py. On a machine with a virtual environment created at ~/pgadmin4, this is~/pgadmin4/lib/python2.7/site-packages/pgadmin4. Ensure you set values for the SECRET_KEY, SECURITY_PASSWORD_SALT and CSRF_SESSION_KEY settings at bare minimum - see config.py for more information and other settings that can be customised. In order to reference other variables from config.py, you may need to include from config import *at the top of config_local.py.

pgAdmin can now be run with a command like python ~/pgadmin4/lib/python2.7/site-packages/pgadmin4/pgAdmin4.py. Finally, point your browser to http://127.0.0.1:5050.

ref: https://askubuntu.com/questions/788457/how-to-install-pgadmin-4-in-server-mode-on-ubuntu-16-04

https://stackoverflow.com/questions/46707935/oserror-errno-13-permission-denied-var-lib-pgadmin

ubuntu安装pgAdmin 4的更多相关文章

  1. ubuntu安装postgresql以及pgadmin4当前最新(4.3)网页版

    pgAdmin4安装 1.安装安装包 sudo apt-get install build-essential libssl-dev libffi-dev libgmp3-dev virtualenv ...

  2. Mac OS、Ubuntu 安装及使用 Consul

    Consul 概念(摘录): Consul 是 HashiCorp 公司推出的开源工具,用于实现分布式系统的服务发现与配置.与其他分布式服务注册与发现的方案,比如 Airbnb 的 SmartStac ...

  3. ubuntu安装mysql

    好记性不如烂笔头,记录一下,ubuntu安装mysql的指令. 安装MySQL: sudo apt-get install mysql-server sudo apt-get install mysq ...

  4. ubuntu安装vim时提示 没有可用的软件包 vim,但是它被其它的软件包引用了 解决办法

    ubuntu安装vim时提示 没有可用的软件包 vim-gtk3,但是它被其它的软件包引用了 解决办法 本人在ubuntu系统安装vim  输入 sudo apt-get install vim 提示 ...

  5. docker 1.8+之后ubuntu安装指定版本docker-engine

    这边记录ubuntu安装过程,首先是官网文档 If you haven’t already done so, log into your Ubuntu instance. Open a termina ...

  6. debian/ubuntu安装桌面环境

    apt-get install xorg apt-get install gnome 然后startx ubuntu 安装Gnome桌面 1.安装全部桌面环境,其实Ubuntu系列桌面实际上有几种桌面 ...

  7. 一个ubuntu phper的自我修养(ubuntu安装)

    ubuntu安装篇 一.ubuntu下载 到ubuntu官网下载适合自己电脑配置的系统版本,此处不做展开. 二.制作USB启动盘 在windows下制作USB启动盘,工具是universal usb ...

  8. ubuntu 安装JAVA jdk的两种方法:

    ubuntu 安装jdk 的两种方式: 1:通过ppa(源) 方式安装. 2:通过官网下载安装包安装. 这里推荐第1种,因为可以通过 apt-get upgrade 方式方便获得jdk的升级 使用pp ...

  9. [其他]Ubuntu安装genymotion后unable to load VirtualBox engine

    问题: Ubuntu安装genymotion后unable to load VirtualBox engine 解决办法: 如果没有安装VirtualBox,要先安装VirtualBox. 安装Vir ...

随机推荐

  1. kickstart

    关闭防火墙.关闭selinux 1.配置DHCP服务 # yum install dhcp -y dhcp配置文件如下 # vi /etc/dhcp/dhcpd.conf 查看路径 # rpm -ql ...

  2. arcgis连接Oracle数据库

    arcgis连接Oracle数据库 配置声明:本人的电脑是win10 64位,安装的Oracle是oracleR11gr2 64  arcgis版本位10.2 安装是在同一台电脑上. 一.首先是安装O ...

  3. Spqrk笔记

    LSM:Least square method 最小二乘法 ALS:Alternating Least Squares 交替最小二乘法 http://blog.csdn.net/dreamer2020 ...

  4. 通过mapreduce把mysql的一张表的数据导到另外一张表中

    怎么安装hadoop集群我在这里就不多说了,我这里安装的是三节点的集群 先在主节点安装mysql 启动mysql 登录mysql 创建数据库,创建表格,先把数据加载到表格 t ,表格t2是空的 mys ...

  5. VMware网络桥接模式与NAT模式共存

      对虚拟机有时我们会有一种需求,即需要虚拟机可以作为单独的主机拥有自己的独立IP,也希望宿主机可以通过NAT模式映射端口到虚拟机. 那么此时怎么办那,其实很简单,虚拟机是支持多网卡设置的,只要在虚拟 ...

  6. python连接数据库——create_engine和conn.cursor

    python操作数据库的方法: 一种是导入sqlalchemy包,另一种是导入psycopg2包. 具体用法如下(此处以postgre数据库举例) 第一种: # 导入包 from sqlalchemy ...

  7. VS2015和QTcreator冲突解决办法

    当我安装了QT(联合VS的版本)和VS时候,刚开始几个月都是可以的,突然有一天不行了,一直显示出错(由于着急没有记录出错截图)!这个时候卸载QT和VS都没有用,两个软件连新建工程都不行了.试了网上说的 ...

  8. 循环内部嵌套ajax请求

    循环内部ajax请求涉及到循环变量的取值问题: 例如: for(var i=0; i<items.length; i++){ zzurl = items[i].url; $.ajax({ typ ...

  9. uva-704-暴力枚举-双向bfs

    题意:俩个转盘,24个数字,每个转盘都可以顺时针,逆时针旋转.终点固定. 问:给定一个起点,能不能在16步内转到终点 解法:双向bfs,终点走8步,起点走8步,判断从起点生成的状态是否在终点里面,如果 ...

  10. 17.1拓展之纯 CSS 创作炫酷的同心圆旋转动画

    效果地址:https://codepen.io/flyingliao/pen/ebjEMm?editors=1100 HTML代码: <div class="loader"& ...