onlyoffice源码编译环境搭建破解
onlyoffice源码编译环境搭建破解
参考:
官方文档
安装依赖项
编译依赖
sudo apt-get install -y python git
其他依赖
sudo apt install net-tools
配置代理
配置全局
使用http代理
不能用socks5代理(curl下载会失败)
需要分别配置HTTP代理和HTTPS代理
注意选择一个快的代理节点
直接全局配置生效
sudo vim /etc/profile
添加如下内容
export HTTP_PROXY=http://127.0.0.1:9910
export HTTPS_PROXY=http://127.0.0.1:9910
使配置生效
source /etc/profile
配置npm
添加
sudo npm config set proxy http://127.0.0.1:9910
sudo npm config set https-proxy http://127.0.0.1:9910
sudo npm config set registry https://registry.npmjs.org/
移除
sudo npm config delete proxy
sudo npm config delete https-proxy
下载编译工具
克隆仓库
git clone https://github.com/ONLYOFFICE/build_tools.git
执行编译脚本
cd build_tools/tools/linux
./automate.py server
安装其他依赖
安装Nginx
sudo apt-get install -y nginx
添加配置
删除默认站点配置
sudo rm -f /etc/nginx/sites-enabled/default
创建新的配置文件,添加如下内容
sudo vim /etc/nginx/sites-available/onlyoffice-documentserver
文件内容
map $http_host $this_host {"" $host;default $http_host;
}
map $http_x_forwarded_proto $the_scheme {default $http_x_forwarded_proto;"" $scheme;
}
map $http_x_forwarded_host $the_host {default $http_x_forwarded_host;"" $this_host;
}
map $http_upgrade $proxy_connection {default upgrade;"" close;
}
proxy_set_header Host $http_host;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $proxy_connection;
proxy_set_header X-Forwarded-Host $the_host;
proxy_set_header X-Forwarded-Proto $the_scheme;
server {listen 0.0.0.0:80;listen [::]:80 default_server;server_tokens off;rewrite ^\/OfficeWeb(\/apps\/.*)$ /web-apps$1 redirect;location / {proxy_pass http://localhost:8000;proxy_http_version 1.1;}location /spellchecker/ {proxy_pass http://localhost:8080/;proxy_http_version 1.1;}
}
配置生效
nginx -s stop
nginx
创建软连接
sudo ln -s \
/etc/nginx/sites-available/onlyoffice-documentserver \
/etc/nginx/sites-enabled/onlyoffice-documentserver
启动nginx
sudo nginx -s reload
查看启动结果
sudo netstat -nlp | grep 80
sudo ps -ef | grep nginx
安装postgreSQL
sudo apt-get install -y postgresql
创建数据库和用户
sudo -i -u postgres psql -c "CREATE DATABASE onlyoffice;"
sudo -i -u postgres psql -c "CREATE USER onlyoffice WITH password 'onlyoffice';"
sudo -i -u postgres psql -c "GRANT ALL privileges ON DATABASE onlyoffice TO onlyoffice;"
初始化数据
在根目录执行
cd /
创建数据库
psql -hlocalhost -Uonlyoffice -d onlyoffice -f \
build_tools/out/linux_64/onlyoffice/documentserver/server/schema/postgresql/createdb.sql
输入密码: onlyoffice
安装RabbitMQ
sudo apt-get install -y rabbitmq-server
生成字体
cd
cd build_tools/out/linux_64/onlyoffice/documentserver/
mkdir fonts
LD_LIBRARY_PATH=${PWD}/server/FileConverter/bin server/tools/allfontsgen \--input="${PWD}/core-fonts" \--allfonts-web="${PWD}/sdkjs/common/AllFonts.js" \--allfonts="${PWD}/server/FileConverter/bin/AllFonts.js" \--images="${PWD}/sdkjs/common/Images" \--selection="${PWD}/server/FileConverter/bin/font_selection.bin" \--output-web='fonts' \--use-system="true"
生成演示主题
cd
cd build_tools/out/linux_64/onlyoffice/documentserver/
LD_LIBRARY_PATH=${PWD}/server/FileConverter/bin server/tools/allthemesgen \--converter-dir="${PWD}/server/FileConverter/bin"\--src="${PWD}/sdkjs/slide/themes"\--output="${PWD}/sdkjs/common/Images"
启动服务
FileConverter
cd build_tools/out/linux_64/onlyoffice/documentserver/server/FileConverter
LD_LIBRARY_PATH=$PWD/bin NODE_ENV=development-linux NODE_CONFIG_DIR=$PWD/../Common/config ./converter
SpellChecker
cd build_tools/out/linux_64/onlyoffice/documentserver/server/SpellChecker
NODE_ENV=development-linux NODE_CONFIG_DIR=$PWD/../Common/config ./spellchecker
DocService
cd build_tools/out/linux_64/onlyoffice/documentserver/server/DocService
NODE_ENV=development-linux NODE_CONFIG_DIR=$PWD/../Common/config ./docservice
扣:三二八五三七七零
onlyoffice源码编译环境搭建破解相关推荐
- spring-framework-5.1.x 源码编译 环境搭建 [ idea:2020.1 ]
spring-framework-5.1.x 源码编译 环境搭建 [ idea:2020.1 ] 一. Gradle下载与安装 软件名称 版本 下载地址 jdk jdk 11.0.5 下载链接 提取码 ...
- Android源码编译环境搭建教程 (一) - Ubuntu系统构建
Android源码编译环境搭建教程 (一) - Ubuntu系统构建 本教程为感兴趣的同学提供Android源码编译的环境搭建,当然这里都是基于windows系统,mac系统也差不多,将相应的软件替换 ...
- netty源码编译环境搭建
最近在看websocket的东西,正好netty中有讲到websocket,所以把netty源码拿来看一下.该文章就是本人在搭建netty源码编译环境的一些收获和感悟.望各位指正!不甚感激.在这里顺便 ...
- 安卓编译安装python_安卓源码编译环境搭建
本编译环境以 Ubuntu 14.04 系统为例 修改软件源(可选) 安装相关依赖 安装Android编译工具JDK 一. 修改软件源(可选) : sudo gedit /etc/apt/source ...
- Android系统源码编译环境搭建(清华镜像,想编译什么版本都可以,只是有JDK和make的版本要求)
上一次,写得有点匆忙,现在补上清华镜像源码的详细下载方法. 编译Android 5.1源代码并烧录到Nexus4(用的是清华镜像的源) 环境准备: 基本环境:ubuntu-14.04-desktop- ...
- Android 源码编译环境搭建
编译环境的搭建主要分为两个大步骤,在此做以记录 1.基础环境的准备 磁盘:需要6GB 以上(为以后可能会有新版本留了空间) Linux系统:Ubuntu6.06以上 2.工具的准备 Java环境:JD ...
- android mtk环境,Ubuntu 14.04 搭建MTK Android源码编译环境搭建
安装必备的工具: BuildEnvironment Requirement ============================================================= ...
- 迅为IMX6开发板非设备树源码编译环境搭建(一)
本小节适用 ITOP-IMX6Q(商业级 2G+16G),ITOP-IMX6Q(工业级 1G+8G), ITOP-IMX6D(商业级 1G+8G) 内核版本为 3.0.35 的系统编译. 13.1 编 ...
- 搭建Flutter Engine源码编译环境
文章目录 资料 编译环境 一些命令 查看项目中用到的flutter环境 出现的问题 GOMA usage was specified but can't be found, falling back ...
- ardupilot java_基于Eclipse IDE的Ardupilot飞控源码阅读环境搭建
基于Eclipse IDE的Ardupilot飞控源码阅读环境搭建 作者:Awesome 日期:2017-10-21 需准备的软件工具 Ardupilot飞控源码 PX4 toolchain JAVA ...
最新文章
- HDU 3306 Another kind of Fibonacci 矩阵快速幂
- L1,L2正则化分析
- boost::quick_exit相关的测试程序
- 阿里巴巴 Arthas 3.1.5版本支持火焰图,快速定位应用热点
- JavaWeb之Cookie
- NATS--NATS Streaming持久化
- PHP正则匹配html标签
- 计算机控制系统第三次作业,城市轨道交通能控制系统第三次作业.ppt
- 安装LaTeX中文字体 xGBKFonts
- PCB Layout的10个细节
- 字符对应的URL编码值集合
- 过支付宝反Xposed登录检测
- C# 多窗口切换的实现
- 「Nescafé26」 Freda的传呼机 【最短路径+树上倍增】
- 语言模型(五)—— Seq2Seq、Attention、Transformer学习笔记
- Docker修改无法启动的容器的配置文件
- 【深度学习】5:CNN卷积神经网络原理
- php gd平涂,水彩画基本技法教学:平涂法
- sublime批量处理excel数据
- 先搞清楚荷、莲、芙蓉的区别