浏览代码

Merge pull request #52 from daschatten/master

Add basic SSL functionality.
tags/v0.37.4
Forrest 9 年前
父节点
当前提交
99ea682cfb
共有 2 个文件被更改,包括 11 次插入0 次删除
  1. +8
    -0
      apache/vhosts/standard.tmpl
  2. +3
    -0
      pillar.example

+ 8
- 0
apache/vhosts/standard.tmpl 查看文件

@@ -48,6 +48,14 @@
{% if site.get('DocumentRoot') != False %}DocumentRoot {{ vals.DocumentRoot }}{% endif %}
{% if site.get('VirtualDocumentRoot') %}VirtualDocumentRoot {{ vals.VirtualDocumentRoot }}{% endif %}

{% if site.SSLCertificateFile is defined %}
SSLEngine on
SSLCertificateFile {{ site.SSLCertificateFile }}
{% if site.SSLCertificateKeyFile is defined %}
SSLCertificateKeyFile {{ site.SSLCertificateKeyFile }}
{% endif %}
{% endif %}

{% for path, dir in site.get('Directory', {}).items() %}
{% set dvals = {
'Options': dir.get('Options', vals.Directory.Options),

+ 3
- 0
pillar.example 查看文件

@@ -44,6 +44,9 @@ apache:

DocumentRoot: /path/to/www/dir/example.com # E.g., /var/www/example.com

SSLCertificateFile = /etc/ssl/mycert.pem # if ssl is desired
SSLCertificateKeyFile = /etc/ssl/mycert.pem.key # if key for cert is needed or in an extra file

Directory:
# "default" is a special case; Adds ``/path/to/www/dir/example.com``
# E.g.: /var/www/example.com

正在加载...
取消
保存