Scriptis是基于Linkis开发的数据分析工具,部署Scriptis前需要先将Linkis进行部署,Linkis的部署手册见:Linkis部署手册
分为两种部署方式,自动化部署和手动部署
进入前端目录wedatasphere-scriptis
在该目录下编辑 vi config.sh
更改前端端口和后端接口地址,后端接口地址为linkis的gateway地址
# Configuring front-end ports
scriptis_port="8088"
# URL of the backend linkis gateway
linkis_url="http://localhost:20401"
# Scriptis ip address
scriptis_ipaddr=$(ip addr | awk '/^[0-9]+: / {}; /inet.*global/ {print gensub(/(.*)\/(.*)/, "\\1", "g", $2)}')
修改完后在该目录下执行:sudo sh install.sh > install.log 2>&1
执行完后可以直接通过在谷歌浏览器访问:http://scriptis_ipaddr:scriptis_port
其中scriptis_port为config.sh里面配置的端口,scriptis_ipaddr为安装机器的IP
如果访问失败:可以通过查看 install.log的日志查看哪一步出错
1.安装Nginx:sudo yum install nginx -y
2.修改配置文件:sudo vi /etc/nginx/conf.d/scriptis.conf 添加如下内容:
server {
listen 8080;# 访问端口
server_name localhost;
#charset koi8-r;
#access_log /var/log/nginx/host.access.log main;
location / {
root /appcom/Install/scriptis/ROOT; # 前端包解压的目录
index index.html index.html;
}
location /ws {#webSocket配置支持
proxy_pass http://192.168.xxx.xxx:9001;#linkis-gateway服务的ip端口
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
}
location /api {
proxy_pass http://192.168.xxx.xxx:9001; # linkis-gateway服务的ip端口
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header x_real_ipP $remote_addr;
proxy_set_header remote_addr $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_http_version 1.1;
proxy_connect_timeout 4s;
proxy_read_timeout 600s;
proxy_send_timeout 12s;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection upgrade;
}
#error_page 404 /404.html;
# redirect server error pages to the static page /50x.html
#
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root /usr/share/nginx/html;
}
}
3.将前端包拷贝到对应的目录:/appcom/Install/scriptis/ROOT; # 前端包解压的目录
4.启动服务sudo systemctl restart nginx
5.执行完后可以直接通过在谷歌浏览器访问:http://nginx_ip:nginx_port
(1)上传文件大小限制
sudo vi /etc/nginx/nginx.conf
更改上传大小
client_max_body_size 200m
(2)接口超时
sudo vi /etc/nginx/conf.d/scriptis.conf
更改接口超时时间
proxy_read_timeout 600s
https://github.com/WeBankFinTech/Scriptis/blob/master/docs/zh_CN/ch1/%E5%89%8D%E5%8F%B0%E9%83%A8%E7%BD%B2%E6%96%87%E6%A1%A3.md