I have a .conf file for my Apache2 server. The thing is, I have 4 different subdomains pointing to the same application, but inside the VirtualHost tag I need a Directory with an alias that can only be accessed from 2 of those 4 subdomains.
Here is what I have:
<IfModule mod_ssl.c>
<VirtualHost *:443>
ServerAdmin webmaster@localhost
DocumentRoot /var/www/html
ErrorLog /home/rafabradley/logs/error.log
CustomLog /home/rafabradley/logs/access.log combined
<Directory /home/rafabradley/anibase-v3/anibase/>
<Files wsgi.py>
Require all granted
</Files>
</Directory>
WSGIDaemonProcess anibasessl python-path=/home/rafabradley/anibase-v3 python-home=/home/rafabradley/venv
WSGIProcessGroup anibasessl
WSGIScriptAlias / /home/rafabradley/anibase-v3/anibase/wsgi.py
ServerName anibase.tk
ServerAlias www.anibase.tk
ServerAlias media.anibase.tk
ServerAlias api.anibase.tk
Include /etc/letsencrypt/options-ssl-apache.conf
SSLCertificateFile /actual/path/to/file
SSLCertificateKeyFile /actual/path/to/file
</VirtualHost>
</IfModule>
Now, I need a directory alias from /static
to /home/rafabradley/anibase-v3/static
, but that can only be accessed from www.anibase.tk and from anibase.tk. Is that possible?