New alias for Internal ContentDB
I run an internal ContentDB, which is an instance of the awesome ContentDB software. The official instance is available at https://content.luanti.org/.
I previously used the random hostname running the containers, http://vm4:5123/ but I wanted a prettier name, so I requisitioned a CNAME record for one of the web hosts, and set up a quick apache httpd conf.
$ dig contentdb.ipa.internal.com contentdb.ipa.internal.com. 604800 IN CNAME server3.ipa.internal.com. server3.ipa.internal.com. 604800 IN A 192.168.5.35
Apache httpd conf
<VirtualHost *:80> ServerName contentdb.ipa.internal.com ServerAlias contentdb RequestHeader set X-Forwarded-Proto "http" RequestHeader set X-Forwarded-Port "80" ProxyPass "/" http://vm4:5123/ ProxyPassReverse "/" http://vm4:5123/ </VirtualHost> <VirtualHost *:443> ServerName contentdb.ipa.internal.com ServerAlias contentdb Include conf.d/ssl-common.cnf Include conf.d/ssl-443.cnf RequestHeader set X-Forwarded-Proto "https" RequestHeader set X-Forwarded-Port "443" ProxyPass "/" http://vm4:5123/ ProxyPassReverse "/" http://vm4:5123/ </VirtualHost>
The TLS settings are out of scope for this post, but I can dredge them up if anybody is desperate. I haven't yet added an additional SAN on the certificate used on this port, so it will throw warnings for now.
Comments