"Redirect all requests to SSL site" - button doesn't stay checked

If I have an SSL on a site and I click:

Web Configuration > Website Option > Redirect all requests to SSL site

(and check “Yes”)

I get the behavior, but the radio button is unchecked when I go look again.

Is that something I did wrong somewhere?

I tried checking the box for:

System Settings, Server Templates, Default Settings, Website for domain, Redirect all HTTP requests to HTTPS

and it runs for awhile so definitely does something… but it did not cause my exiting sites on the template to force to https though (I do have some sites without SSL which I reasoned might have broken this whole thing)

The radio button above looks like it writes:

RewriteRule ^/(?!.well-known)(.*)$ https://%{HTTP_HOST}/$1 [R]

to the bottom of port 80 section of /etc/apache2/site-enabled/[the-domain].conf, just between:

</FilesMatch>
RewriteRule ^/(?!.well-known)(.*)$ https://%{HTTP_HOST}/$1 [R]
</VirtualHost>

But the checkbox made no such change.

SYSTEM INFORMATION
OS type and version Ubuntu 24.04.4
Virtualmin version 7.50.0

Hello,

Thanks for the feedback!

This is a known bug and will be fixed in the upcoming Virtualmin release.

In the meantime, you can apply the following patch to make it work right now:

webmin patch https://github.com/virtualmin/virtualmin-gpl/commit/5f7f6c2

Cool, thanks!

1 Like

This topic was automatically closed 8 days after the last reply. New replies are no longer allowed.