Configure HTTP Basic Auth for repository and add install-repo.sh

This commit is contained in:
bart
2026-10-20 21:34:57 +02:00
parent eb3e451a87
commit 97a437bf27
2 changed files with 182 additions and 18 deletions
+19 -18
View File
@@ -1,13 +1,13 @@
<VirtualHost *:80>
ServerName repository.eendoe.nl
ProxyRequests off
ProxyPreserveHost on
ServerName repository.eendoe.nl
ProxyRequests off
ProxyPreserveHost on
RewriteEngine on
RewriteCond %{SERVER_NAME} =repository.bnhmeijer.nl
RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,NE,R=permanent]
RewriteEngine on
RewriteCond %{SERVER_NAME} =repository.eendoe.nl [OR]
RewriteCond %{SERVER_NAME} =repository.bnhmeijer.nl
RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,NE,R=permanent]
</VirtualHost>
@@ -17,20 +17,21 @@
Protocols h2 h2c http/1.1
ServerName repository.eendoe.nl
DocumentRoot /sites/repository/binaries
<Directory /sites/repository/binaries>
AllowOverride None
Options FollowSymLinks
DocumentRoot /sites/repository/binaries
AuthType Basic
AuthName "Eendoe Private Repository"
AuthUserFile /sites/repository/.htpasswd
Require valid-user
</Directory>
<Directory /sites/repository/binaries>
AllowOverride All
Options FollowSymLinks
Order deny,allow
allow from all
Require all granted
</Directory>
Include /etc/letsencrypt/options-ssl-apache.conf
SSLCertificateFile /etc/letsencrypt/live/bm4.nl-0002/fullchain.pem
SSLCertificateKeyFile /etc/letsencrypt/live/bm4.nl-0002/privkey.pem
Include /etc/letsencrypt/options-ssl-apache.conf
SSLCertificateFile /etc/letsencrypt/live/bm4.nl-0002/fullchain.pem
SSLCertificateKeyFile /etc/letsencrypt/live/bm4.nl-0002/privkey.pem
</VirtualHost>