superset 安装配置

时间:2020-12-15 08:52:40

一、配置python虚拟环境,请参考

superset依赖python3.6环境

https://www.cnblogs.com/xibuhaohao/p/9994854.html

二、安装配置superset

参考superset官网

1.安装依赖包

For Fedora and RHEL-derivatives, the following command will ensure that the required dependencies are installed:

sudo yum upgrade python-setuptools

sudo yum install gcc gcc-c++ libffi-devel python-devel python-pip python-wheel openssl-devel libsasl2-devel openldap-devel

2.升级pip,用来符合python的版本

Put all the chances on your side by getting the very latest pip and setuptools libraries.:

pip install --upgrade setuptools pip

3.安装与配置superset

Follow these few simple steps to install Superset.:

# Install superset

pip install superset

# Create an admin user (you will be prompted to set a username, first and last name before setting a password)

fabmanager create-admin --app superset

# Initialize the database

superset db upgrade

# Load some data to play with

superset load_examples

# Create default roles and permissions

superset init

# To start a development web server on port 8088, use -p to bind to another port

superset runserver -d

三、登录superset连接数据库

superset 安装配置

1.配置MySQL连接

一开始配置的时候报出错误,没有MySQL数据库连接驱动,到python虚拟环境安装,一直报错

按照观方

superset 安装配置

superset 安装配置

2.解决报错

通过搜索,找到一片文章,需要安装mysqlclient的依赖包 https://blog.csdn.net/xc_zhou/article/details/80871374

yum install mysql-devel

再次安装mysqlclinet则ok

superset 安装配置

3.配置superset连接数据库

mysql://dbadmin:dbadmin@127.0.0.1:3306/dbadmin

superset 安装配置