量子巡游者
2018-04-17 20:35 Moderator
本帖最后由 MMDMM 于 2020-6-10 11:56 编辑
六、apahce设置Copy the Code
Copy the Code
Copy the CodeCopy the Code
Copy the Code
六、apahce设置
需要做两件事情:
1、开启伪静态
修改/etc/httpd/conf/httpd.conf文件
- ## Possible values for the Options directive are “None”, “All”,# or any combination of:# Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews## Note that “MultiViews” must be named *explicitly* — “Options All”# doesn’t give it to you.## The Options directive is both complicated and important. Please see# for more information.#Options Indexes FollowSymLinks## AllowOverride controls what directives may be placed in .htaccess files.# It can be “All”, “None”, or any combination of the keywords:# Options FileInfo AuthConfig Limit#AllowOverride None## Controls who can get stuff from this server.#Require all granted>
把:AllowOverride None 改成:AllowOverride All 再重启apache systemctl restart httpd
2、做反向代理,优米云服务可通过apache被外网访问,这样就不需要对外提供两个端口了(本手册中只需要80端口就可以客户端登录及网页后台登录了)
做反向代理需在etc/httpd/conf.d/目录下新增一个文件proxy.conf
加入以下内容:
- ProxyRequests OffProxyPass /app/file http://127.0.0.1:1891/app/fileProxyPassReverse /app/file http://127.0.0.1:1891/app/fileProxyPass /app/notice http://127.0.0.1:1891/app/noticeProxyPassReverse /app/notice http://127.0.0.1:1891/app/noticeProxyPass /app/user http://127.0.0.1:1891/app/userProxyPassReverse /app/user http://127.0.0.1:1891/app/user
注意:1891端口是优米云服务的端口,没特殊需要不要改动
另外,不要直接把 http://127.0.0.1:1891/app
做反向代理,这会把服务器的一些内部通讯暴露给外网,增加系统隐患。
七、关闭centos自带的SELinux
SELinux的安全机制极为严格,且使用白名单机制,如没特殊需求请关闭,若不想关闭请自行研究如何配置
如何关闭请参考这篇文章
八、安装sphinx
sphinx是一个全文搜索引擎,采用编译安装
- wget http://sphinxsearch.com/files/sphinx-2.2.11-release.tar.gztar xzvf sphinx-2.2.11-release.tar.gzcd sphinx-2.2.11-release
在centos7上需要修改一个文件才能正常使用,修改config/config.h文件,在最后一行加上:#define USE_LITTLE_ENDIAN = 1,然后再开始
- ./configure –prefix=/usr/local/sphinx/makemake install
如果make遇到错误,先安装编译器
- yum install gcc gcc-c++
Reply Like 0 View the author


中文 


优米云盘linux版安装手册
发布于:2018年3月31日下午9:01