Answer the question
In order to leave comments, you need to log in
Do I need to leave the config with SSL only?
I manually installed LAMP. Then I connected an SSL certificate from Lets Encrypt and I have a question.
My main site config ivan-glazkov-ru.conf
But since I connected https, the corresponding config was created, more specifically ivan-glazkov-ru-le-ssl.conf
Should they both be executed? Or because I now have https, then the standard config ivan-glazkov-ru.conf needs to be turned off?
+ here are the screenshots of the configs themselves,
this is ivan-glazkov-ru.conf
and this is ivan-glazkov-ru-le-ssl.conf
Answer the question
In order to leave comments, you need to log in
In my opinion, this is obvious, there are a lot of instructions on the Internet for switching from http to https
, in none of them you will find deleting the config.
If the site has already switched to https and the weight has been transferred, then the old http must be re-pasted with a redirect to https
############################################################################
#### Перенаправляем протокол http на https ####
############################################################################
RewriteCond %{ENV:HTTPS} !on
# Проверяем наличие https в URL.
RewriteRule ^.*$ https://%{SERVER_NAME}%{REQUEST_URI} [R=301,L]
# Перенаправляем протокол на http.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question