gerrit 配置 apache2 反向代理(转载)
Apache 2 Configuration
To run Gerrit behind an Apache server using mod_proxy, enable the necessary Apache2 modules:
a2enmod proxy_http
a2enmod ssl ; # optional, needed for HTTPS / SSL
Configure an Apache VirtualHost to proxy to the Gerrit daemon, setting the ProxyPass line to use the http:// URL configured above. Ensure the path of ProxyPass and httpd.listenUrl match, or links will redirect to incorrect locations.
<VirtualHost *>
ServerName review.example.com ProxyRequests Off
ProxyVia Off
ProxyPreserveHost On <Proxy *>
Order deny,allow
Allow from all
</Proxy> AllowEncodedSlashes On
ProxyPass /r/ http://127.0.0.1:8081/r/ nocanon
</VirtualHost>
The two options AllowEncodedSlashes On and ProxyPass .. nocanon are required since Gerrit 2.6.
SSL
To enable Apache to perform the SSL processing, use proxy-https:// in httpd.listenUrl within Gerrit’s configuration file, and enable the SSL engine in the Apache VirtualHost block:
<VirtualHost *:443>
SSLEngine on
SSLCertificateFile conf/server.crt
SSLCertificateKeyFile conf/server.key ... same as above ...
</VirtualHost>
See the Apache mod_ssl documentation for more details on how to configure SSL within the server, like controlling how strong of an encryption algorithm is required.
Troubleshooting
If you are encountering Page Not Found errors when opening the change screen, your Apache proxy is very likely decoding the passed URL. Make sure to either useAllowEncodedSlashes On together with ProxyPass .. nodecode or alternatively a mod_rewrite configuration with AllowEncodedSlashes NoDecode set.
From:http://gerrit-documentation.googlecode.com/svn/Documentation/2.6/config-reverseproxy.html
gerrit 配置 apache2 反向代理(转载)的更多相关文章
- CentOS 7 学习(二) 配置Nginx反向代理
CentOS 7 学习(二) 配置Nginx反向代理 Nginx可以通过php-fpm来运行PHP程序,也可以转向apache,让apache调用php程序来运行. 不过对于Nginx来说,其反向代理 ...
- CentOS安装Nginx,并配置nodejs反向代理
安装介绍 安装位置:/usr/local/nginx nginx安装包下载地址:http://nginx.org/download/nginx-1.7.11.tar.gz 安装依赖软件 安装nginx ...
- 为docker私有registry配置nginx反向代理
公司的Docker私有registry已经搭建好了,用官方的registry image很容易就搭建好了.现在就是要用nginx的反向代理把它放出来,以便在外网可以访问. 我的上一篇blog 讲了如何 ...
- 配置apache反向代理进行跨域
配置apache反向代理 打开配置文件httpd.conf 开启 proxy_http_module 和 proxy_module 模块,将#号删除 #LoadModule proxy_module ...
- 使用SSL配置Nginx反向代理的简单指南
反向代理是一个服务器,它接收通过Web发出的请求,即http和https,然后将它们发送到后端服务器(或服务器).后端服务器可以是单个或一组应用服务器,如Tomcat,wildfly或Jenkins等 ...
- Nginx配置实例-反向代理实例:根据访问的路径跳转到不同端口的服务中
场景 Ubuntu Server 16.04 LTS上怎样安装下载安装Nginx并启动: https://blog.csdn.net/BADAO_LIUMANG_QIZHI/article/detai ...
- 配置LANMP环境(7)-- 配置nginx反向代理,与配置apache虚拟主机
一.配置nginx反向代理 1.修改配置文件 vim /etc/nginx/nginx.conf 在35行http下添加一下内容: include /data/nginx/vhosts/*.conf; ...
- apache2反向代理node.js应用
在之前记录的随笔中,只是介绍了怎么在apache2中使用proxy模块,后来查到了一些资料,可以通过下面网址查看配置块的详细参数信息 http://man.ddvip.com/soft/apache2 ...
- apache2反向代理
1.安装 Apache2 sudo apt-get install apache2 2.重启服务器 sudo /etc/init.d/apache2 restart 3.虚拟主机配置 启用这几个模块 ...
随机推荐
- dotnetConf
https://channel9.msdn.com/Events/dotnetConf/2016 https://channel9.msdn.com/Events/dotnetConf/2016?so ...
- Unity3D研究院编辑器之脚本获取资源内存和硬盘大小
内存 使用Profiler可以查看某个资源的内存占用情况,但是必须启动游戏,并且待查看的资源已经载入游戏中.我希望的是不启动游戏,也能看到它的内存好做统计. 硬盘 由于unity中的资源压缩格式记录在 ...
- pgbouncer配置
DESCRIPTION pgbouncer is a PostgreSQL connection pooler. Any target application can be connected to ...
- jQuery easyui datagrid数据绑定
1.绑定json数据 <!DOCTYPE html> <html> <head> <meta http-equiv="Content-Type&qu ...
- Windows动态链接库DLL
1.什么是DLLDLL,即动态链接库,是包含若干个函数的库文件,可供其他程序运行时调用. 2.DLL的优缺点优点:代码重用,可供多个程序同时调用 缺点:易发生版本冲突当新版本的动态链接库不兼容旧版本时 ...
- python数据库操作pymysql
安装数据库: pip3 install pymysql 进行数据库的更新.插入.查询等操作: #!/usr/bin/python3.4 # -*- coding: utf-8 -*- #------- ...
- Redis学习手册(服务器管理)
转:http://www.cnblogs.com/stephen-liu74/archive/2012/02/27/2369480.html 一.概述: Redis在设计之初就被定义为长时间不间断运行 ...
- R(八): R分词统计-老九门
分析文本内容基本的步骤:提取文本中的词语 -> 统计词语频率 -> 词频属性可视化.词频:能反映词语在文本中的重要性,一般越重要的词语,在文本中出现的次数就会越多.词云:让词语的频率属性可 ...
- sql在添加新列时同时指定default约束名称
alter table tab_testadd col_test NOT NULL CONSTRAINT DFtab_test_col_test DEFAULT 1 引用:http://www.uzz ...
- Python基础教程【读书笔记】 - 2016/7/19
希望通过博客园持续的更新,分享和记录Python基础知识到高级应用的点点滴滴! 第八波:第4章 字典:当索引不好用时 将学到一种通过名字引用值的数据结构,这种结构类型称为映射mapping.字典是P ...