Centos下安装superset完整安装教程

5 篇文章 0 订阅
3 篇文章 0 订阅

Centos下安装superset

1.环境准备

Anaconda安装教程

# centos系统准备
[ctyun@centos--tt3hyyagh1 ~]$ cat /etc/redhat-release 
CentOS Linux release 7.6.1810 (Core)

# 安装anaconda,详细参考上述Anaconda安装教程
[ctyun@centos--tt3hyyagh1 ~]$ conda -V
conda 4.6.11

# 创建虚拟环境
[ctyun@centos--tt3hyyagh1 ~]$ conda create -n superset python=3.7.4

#进入虚拟环境
[ctyun@centos--tt3hyyagh1 ~]$ source activate superset
(superset) [ctyun@centos--tt3hyyagh1 ~]$ 

#退出虚拟环境
(superset) [ctyun@centos--tt3hyyagh1 ~]$ source deactivate

# Linux下查看已有虚拟环境
[ctyun@centos--tt3hyyagh1 ~]$ conda-env list
WARNING: The conda.compat module is deprecated and will be removed in a future release.
WARNING: The conda.compat module is deprecated and will be removed in a future release.
# conda environments:
#
base                  *  /home/ctyun/anaconda3
superset                 /home/ctyun/anaconda3/envs/superset

2.superset安装部署

# wget https://github.com/Warding/InternetRecords/blob/master/%E5%B7%A5%E5%85%B7%E4%BD%BF%E7%94%A8/superset_requirements.txt
(这里如果下载后安装失败,可以进入到链接,将requirements直接手动复制编辑成superset_requirements.txt进行安装)

# pip install -r superset_requirements.txt -- 安装依赖包

# superset db upgrade -- 初始化db环境

# export FLASK_APP=superset --账户设定

# flask fab create-admin --创建账户按提示输入账密就好

# superset load_examples --下载样例数据,可不执行

# superset init --superset环境初始化

# superset run -p 8088 -h 10.10.2.248  --with-threads   -- superset 启动(这里面我指定了端口和IP,分别是-p 和 -h 参数,建议指定成自己的服务器IP和某个端口,网页访问的时候,**还需要将这个端口对外开放,不然你本地登录网页访问会无法成功**)

# 或者直接运行 superset 服务。superset 的 Web 服务默认端口为 8088,你可以通过 -p 参数指定端口。
superset runserver

3.防火墙放开8808端口

# 查看端口
netstat -tunlp|grep 8088

# 法1:放开所有ip
sudo firewall-cmd --zone=public --add-port=8808/tcp --permanent   
sudo firewall-cmd --reload
firewall-cmd --list-all  

# 法2:放开指定网段ip
firewall-cmd --permanent --add-rich-rule="rule family="ipv4" source address="10.10.0.0/16" port protocol="tcp" port="8808" accept"
sudo firewall-cmd --reload

#  在本地telenet 服务器ip:端口 ,确认端口是否可通

在这里插入图片描述

4.supeset部署完成啦~~~

打开登录页面http://10.10.2.248:8088/
在这里插入图片描述

  • 0
    点赞
  • 4
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值