Describe the Bug
It appears that some assets are hard-coded to http. When running the site with a redirect of all traffic to https, the loading of some css pages, etc. fail.
Steps to Reproduce
Using certbot to create certs and update confs.
bookstack.conf:
<VirtualHost *:80>
ServerName book.server.com
ServerAdmin webmaster@localhost
DocumentRoot /var/www/bookstack/public/
redirect / https://book.server.com/
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
RewriteCond %{SERVER_NAME} =book.server.com
RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,NE,R=permanent]
</VirtualHost>
bookstack-le-ssl.conf
IfModule mod_ssl.c>
<VirtualHost *:443>
ServerName book.server.com
ServerAdmin webmaster@localhost
DocumentRoot /var/www/bookstack/public/
SSLEngine On
<Directory /var/www/bookstack/public/>
Options Indexes FollowSymLinks
AllowOverride None
Require all granted
<IfModule mod_rewrite.c>
<IfModule mod_negotiation.c>
Options -MultiViews -Indexes
</IfModule>
RewriteEngine On
# Handle Authorization Header
RewriteCond %{HTTPS:Authorization} .
RewriteRule .* - [E=HTTPS_AUTHORIZATION:%{HTTPS:Authorization}]
# Redirect Trailing Slashes If Not A Folder...
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} (.+)/$
RewriteRule ^ %1 [L,R=301]
# Handle Front Controller...
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ index.php [L]
</IfModule>
</Directory>
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
SSLCertificateFile /etc/letsencrypt/live/book.server.com./fullchain.pem
SSLCertificateKeyFile /etc/letsencrypt/live/book.server.com/privkey.pem
Include /etc/letsencrypt/options-ssl-apache.conf
</VirtualHost>
</IfModule>
Expected Behaviour
Same as for http - but encrypted.
Screenshots or Additional Context
style sheets do not load and it looks pretty ugly.
Browser Details
firefox
Exact BookStack Version
V22.02.3
PHP Version
PHP 7.4.3 (cli) (built: Mar 2 2022 15:36:52) ( NTS )
Hosting Environment
Linux server 5.4.0-97-generic #110-Ubuntu SMP Thu Jan 13 18:22:13 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
Describe the Bug
It appears that some assets are hard-coded to http. When running the site with a redirect of all traffic to https, the loading of some css pages, etc. fail.
Steps to Reproduce
Using certbot to create certs and update confs.
bookstack.conf:
bookstack-le-ssl.conf
Expected Behaviour
Same as for http - but encrypted.
Screenshots or Additional Context
style sheets do not load and it looks pretty ugly.
Browser Details
firefox
Exact BookStack Version
V22.02.3
PHP Version
PHP 7.4.3 (cli) (built: Mar 2 2022 15:36:52) ( NTS )
Hosting Environment
Linux server 5.4.0-97-generic #110-Ubuntu SMP Thu Jan 13 18:22:13 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux