-
Notifications
You must be signed in to change notification settings - Fork 12
/
Copy pathexample-openevse-apache.conf
63 lines (46 loc) · 1.87 KB
/
example-openevse-apache.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
<VirtualHost *:80>
ServerName openevse.bigjungle.net
DocumentRoot /vagrant/src/data
ErrorLog ${APACHE_LOG_DIR}/openevse_error.log
CustomLog ${APACHE_LOG_DIR}/openevse_access.log combined
ProxyRequests Off
ProxyPass "/ws" "ws://localhost:3000/ws"
ProxyPassReverse "/ws" "ws://localhost:3000/ws"
RewriteEngine on
#LogLevel alert rewrite:trace6
# Redirect web sockets
RewriteRule /ws ws://localhost:3000/ws [L,P]
# Redirect missing files to the ap server
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([^.?]+)$ http://localhost:3000%{REQUEST_URI} [L,P]
DirectoryIndex home.htm
</VirtualHost>
<VirtualHost *:443>
ServerName openevse.bigjungle.net
DocumentRoot /vagrant/src/data
ErrorLog ${APACHE_LOG_DIR}/openevse_error.log
CustomLog ${APACHE_LOG_DIR}/openevse_access.log combined
# SSL Engine Switch:
# Enable/Disable SSL for this virtual host.
SSLEngine on
SSLCertificateFile /etc/ssl/certs/ssl-cert-snakeoil.pem
SSLCertificateKeyFile /etc/ssl/private/ssl-cert-snakeoil.key
ProxyRequests Off
ProxyPass "/ws" "ws://localhost:3000/ws"
ProxyPassReverse "/ws" "ws://localhost:3000/ws"
RewriteEngine on
#LogLevel alert rewrite:trace6
# Redirect web sockets
RewriteRule /ws ws://localhost:3000/ws [L,P]
# Redirect missing files to the ap server
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([^.?]+)$ http://localhost:3000%{REQUEST_URI} [L,P]
DirectoryIndex home.htm
</VirtualHost>
<Directory /vagrant/src/data>
Options Indexes FollowSymLinks
AllowOverride All
Require all granted
</Directory>