1

I have a webserver on my raspberry pi, my url I bought on strato.de and my dyndns is on noip.com. The redirecting from my url to the raspberry pi is fine and works. Now I wanted to use automatically redirection from http-request to https. Therefore I installed letsencrypt and create a ssl certificate file. Also I enabled ssl on strato.de for my url. I tested it with https://www.myurl.de/ and it works but if I use http://www.myurl.de I get this error:

Network Error (tcp_error) A communication error occurred: "Connection refused" The Web Server may be down, too busy, or experiencing other problems preventing it from responding to requests. You may wish to try again at a later time. Transaction ID: b5151b4415351db8-000000008e3c905d-000000005c177c1e For assistance, contact your network support team. Your request was categorized by Blue Coat Web Filter as 'Dynamic DNS Host'. If you wish to question or dispute this result, please click here.

It sounds to me as something in the config-files are wrong. Therefore is here my code of the 000-default.conf and default-ssl.conf file.

000-default.conf

<VirtualHost *:80>
    ServerAdmin webmaster@localhost
    DocumentRoot /var/www/html
    ErrorLog ${APACHE_LOG_DIR}/error.log
    CustomLog ${APACHE_LOG_DIR}/access.log combined
    <IfModule mod_rewrite.c>
        RewriteEngine On
        RewriteRule ^(.*)$ https://%{HTTP_HOST}$1 [R=301,L]
    </IfModule>
</VirtualHost>

default-ssl.conf:

<IfModule mod_ssl.c>
    <VirtualHost *:443>
        ServerAdmin webmaster@localhost
        DocumentRoot /var/www/html
        ErrorLog ${APACHE_LOG_DIR}/error.log
        CustomLog ${APACHE_LOG_DIR}/access.log combined
        SSLEngine on
        SSLCertificateFile /etc/letsencrypt/live/<noip-dyndns-name>.com/fullchain.pem
        SSLCertificateKeyFile /etc/letsencrypt/live/<noip-dyndns-name>.com/privkey.pem
        <FilesMatch "\.(cgi|shtml|phtml|php)$">
            SSLOptions +StdEnvVars
        </FilesMatch>
        <Directory /usr/lib/cgi-bin>
            SSLOptions +StdEnvVars
        </Directory>
    </VirtualHost>
</IfModule>

Does someone see my mistake I made?

Z4che
  • 41
  • 1
  • 5
  • This raises so many questions ... Like why do you have to enable ssl on Strato for your domain, if the domain is hosted on your Pi? What exactly is Strato doing in this setup? The error message you posted does not look like an Apache error message, where is that coming from? – A. Scherbaum Dec 18 '18 at 16:46
  • Enableing ssl on strato is not necessarry, thats right. The error message is from the browser if I´ll do an http request for my webserver. – Z4che Dec 19 '18 at 08:34
  • No, that is not a typical Apache error message. Something else generated that message, therefore you are not connected to your webserver. – A. Scherbaum Dec 19 '18 at 13:09
  • I can´t get access with http://www.myurl.de but with https://www.myurl.de it works... – Z4che Dec 19 '18 at 13:11

0 Answers0