Refs #265 Make vhost ssl type configurable

This commit is contained in:
cytopia 2020-01-04 17:06:08 +01:00
parent 6fa7a84bd3
commit 2e09f7f0f8
No known key found for this signature in database
GPG Key ID: 6D56EDB8695128A2
3 changed files with 40 additions and 2 deletions

View File

@ -245,7 +245,7 @@ services:
- MAIN_VHOST_ENABLE=${DEVILBOX_UI_ENABLE}
- MAIN_VHOST_STATUS_ENABLE=1
- MAIN_VHOST_STATUS_ALIAS=/devilbox-httpd-status
- MAIN_VHOST_SSL_TYPE=both
- MAIN_VHOST_SSL_TYPE=${HTTPD_VHOST_SSL_TYPE:-both}
- MAIN_VHOST_SSL_GEN=1
- MAIN_VHOST_SSL_CN=${DEVILBOX_UI_SSL_CN:-localhost}
@ -256,7 +256,7 @@ services:
- MASS_VHOST_TLD=.${TLD_SUFFIX}
- MASS_VHOST_DOCROOT=${HTTPD_DOCROOT_DIR}
- MASS_VHOST_TPL=${HTTPD_TEMPLATE_DIR}
- MASS_VHOST_SSL_TYPE=both
- MASS_VHOST_SSL_TYPE=${HTTPD_VHOST_SSL_TYPE:-both}
- MASS_VHOST_SSL_GEN=1
##

View File

@ -1235,6 +1235,27 @@ This will then output ``development``.
Web server
----------
HTTPD_SSL_TYPE
^^^^^^^^^^^^^^
SSL (HTTP/HTTPS) settings for automated vhost generation.
By default each project will have two vhosts (one for HTTP and one for HTTPS).
You can control the SSL settings for your projects via the below stated values.
This is internally achieved via the ``-m`` argument of |ext_lnk_project_vhost_gen|
* ``both`` will serve HTTP and HTTPS for all projects
* ``redir`` will always redirect HTTP to HTTPS
* ``ssl`` will only serve HTTPS
* ``plain`` will only serve HTTP
+-----------------------+-----------------------------------------+------------------+
| Name | Allowed values | Default value |
+=======================+=========================================+==================+
| ``HTTPD_SSL_TYPE`` | ``both``, ``redir``, ``ssl``, ``plain`` | ``both`` |
+-----------------------+-----------------------------------------+------------------+
.. _env_httpd_docroot_dir:
HTTPD_DOCROOT_DIR

View File

@ -510,6 +510,23 @@ HOST_PORT_HTTPD=80
HOST_PORT_HTTPD_SSL=443
###
### SSL (HTTP/HTTPS) settings for automated vhost generation
###
### By default each project will have two vhosts (one for HTTP and one for HTTPS).
### You can control the SSL settings for your projects via the below stated values.
###
### This is internally achieved via the '-m' argument of https://github.com/devilbox/vhost-gen
###
### Values:
### * both: Serve HTTP and HTTPS for all projects
### * redir: HTTP always redirects to HTTPS
### * ssl: Only serve HTTPS
### * plain: Only serve HTTP
###
HTTPD_VHOST_SSL_TYPE=both
###
### Document Root Subdirectory
###