diff --git a/src/templates/apache2/wsgi-both.conf b/src/templates/apache2/wsgi-both.conf
index fb6bbb3..0595440 100644
--- a/src/templates/apache2/wsgi-both.conf
+++ b/src/templates/apache2/wsgi-both.conf
@@ -10,7 +10,7 @@
%%CHAINLINE%%
- WSGIDaemonProcess %%fqdn%% python-home=%%VENV%% python-path=%%document_root%%/ socket-user=#%%UID%%
+ WSGIDaemonProcess %%fqdn%% python-home=%%account_root%%/%%VENV%% python-path=%%document_root%%/ socket-user=#%%UID%%
WSGIProcessGroup %%fqdn%%
WSGIScriptAlias / %%document_root%%/%%APP_SUBDIR%%/wsgi.py process-group=%%fqdn%%
@@ -35,7 +35,7 @@
SetEnv LOGIN "%%UID%%-%%LOGIN%%"
- WSGIDaemonProcess %%fqdn%% python-home=%%VENV%% python-path=%%document_root%%/ socket-user=#%%UID%%
+ WSGIDaemonProcess %%fqdn%% python-home=%%account_root%%/%%VENV%% python-path=%%document_root%%/ socket-user=#%%UID%%
WSGIProcessGroup %%fqdn%%
WSGIScriptAlias / %%document_root%%/%%APP_SUBDIR%%/wsgi.py process-group=%%fqdn%%
diff --git a/src/templates/apache2/wsgi-http.conf b/src/templates/apache2/wsgi-http.conf
index 7eba0b1..b602b46 100644
--- a/src/templates/apache2/wsgi-http.conf
+++ b/src/templates/apache2/wsgi-http.conf
@@ -22,7 +22,7 @@
AssignUserId #%%UID%% #%%GID%%
SetEnv LOGIN "%%UID%%-%%LOGIN%%"
- WSGIDaemonProcess %%fqdn%% python-home=%%VENV%% python-path=%%document_root%%/ socket-user=#%%UID%%
+ WSGIDaemonProcess %%fqdn%% python-home=%%account_root%%/%%VENV%% python-path=%%document_root%%/ socket-user=#%%UID%%
WSGIProcessGroup %%fqdn%%
WSGIScriptAlias / %%document_root%%/%%APP_SUBDIR%%/wsgi.py process-group=%%fqdn%%
diff --git a/src/templates/apache2/wsgi-https.conf b/src/templates/apache2/wsgi-https.conf
index f7f7cc5..97ffdaa 100644
--- a/src/templates/apache2/wsgi-https.conf
+++ b/src/templates/apache2/wsgi-https.conf
@@ -10,7 +10,7 @@
%%CHAINLINE%%
- WSGIDaemonProcess %%fqdn%% python-home=%%VENV%% python-path=%%document_root%%/ socket-user=#%%UID%%
+ WSGIDaemonProcess %%fqdn%% python-home=%%account_root%%/%%VENV%% python-path=%%document_root%%/ socket-user=#%%UID%%
WSGIProcessGroup %%fqdn%%
WSGIScriptAlias / %%document_root%%/%%APP_SUBDIR%%/wsgi.py process-group=%%fqdn%%
@@ -39,5 +39,5 @@
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !/cgi-bin/
RewriteCond %{REQUEST_FILENAME} !/.well-known/acme-challenge/
- RewriteRule ^/(.*)$ http://%%fqdn%%/$1 [R=301,L]
+ RewriteRule ^/(.*)$ https://%%fqdn%%/$1 [R=301,L]
diff --git a/src/templates/apache2/wsgi.conf b/src/templates/apache2/wsgi.conf
index 7eba0b1..b602b46 100644
--- a/src/templates/apache2/wsgi.conf
+++ b/src/templates/apache2/wsgi.conf
@@ -22,7 +22,7 @@
AssignUserId #%%UID%% #%%GID%%
SetEnv LOGIN "%%UID%%-%%LOGIN%%"
- WSGIDaemonProcess %%fqdn%% python-home=%%VENV%% python-path=%%document_root%%/ socket-user=#%%UID%%
+ WSGIDaemonProcess %%fqdn%% python-home=%%account_root%%/%%VENV%% python-path=%%document_root%%/ socket-user=#%%UID%%
WSGIProcessGroup %%fqdn%%
WSGIScriptAlias / %%document_root%%/%%APP_SUBDIR%%/wsgi.py process-group=%%fqdn%%