38 lines
1.2 KiB
Plaintext
38 lines
1.2 KiB
Plaintext
# Harheimer TC Website - HTTP VirtualHost
|
|
# Speichern unter: /etc/apache2/sites-available/harheimertc.tsschulz.de.conf
|
|
|
|
<VirtualHost *:80>
|
|
ServerName harheimertc.tsschulz.de
|
|
ServerAdmin admin@tsschulz.de
|
|
|
|
DocumentRoot /var/www/harheimertc/dist
|
|
|
|
ErrorLog ${APACHE_LOG_DIR}/harheimertc-error.log
|
|
CustomLog ${APACHE_LOG_DIR}/harheimertc-access.log combined
|
|
|
|
# SPA Fallback für Nuxt.js
|
|
<Directory "/var/www/harheimertc/dist">
|
|
Options Indexes FollowSymLinks
|
|
AllowOverride All
|
|
Require all granted
|
|
|
|
# Fallback für Client-Side Routing
|
|
RewriteEngine On
|
|
RewriteBase /
|
|
RewriteRule ^index\.html$ - [L]
|
|
RewriteCond %{REQUEST_FILENAME} !-f
|
|
RewriteCond %{REQUEST_FILENAME} !-d
|
|
RewriteRule . /index.html [L]
|
|
</Directory>
|
|
|
|
# API-Routes für Nuxt Server (falls Server-Side Rendering verwendet wird)
|
|
ProxyPreserveHost On
|
|
ProxyPass /api/ http://localhost:3100/api/
|
|
ProxyPassReverse /api/ http://localhost:3100/api/
|
|
|
|
# Redirect zu HTTPS (optional - kann später aktiviert werden)
|
|
# RewriteEngine On
|
|
# RewriteCond %{SERVER_NAME} =harheimertc.tsschulz.de
|
|
# RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,NE,R=permanent]
|
|
</VirtualHost>
|