I have managed to redirect a subdomain hosted on my host provider (1and1) to an EC2 instance on AWS by implementing the following steps:
- creating an elastic IP on my EC2 instance
- adding the elastic IP address to the DNS settings of my subdomain
Question: How can I now allow for https request? The subdomain has a working SSl certificate but when I call the https://mysubdomain.example.com I am getting the following error:
This site can't be reached, mysubdomain.example.com refused to connect.
The security group setup on my EC2 instance allows for https, although it seems that the port 443 is not correctly open as typing:
sudo netstat -tlnp
returns:
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 10144/sshd
tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN 3081/master
tcp6 0 0 :::80 :::* LISTEN 16084/httpd
tcp6 0 0 :::22 :::* LISTEN 10144/sshd
tcp6 0 0 ::1:25 :::* LISTEN 3081/master
Any idea? The EC2 instance is running on an Apache VirtualHost. Many thanks.
I am running on Apache and the .conf looks like this:
<VirtualHost *:80>
Servername xx.xx.xx.xx
WSGIPassAuthorization On
WSGIDaemonProcess bottle_app threads=5 python-path=/var/www/bottle_app/:/usr/lib/python2.7/site- packages/:/usr/lib64/python2.7/site-packages/
WSGIScriptAlias / /var/www/bottle_app/app.wsgi
<Directory /var/www/bottle_app>
WSGIProcessGroup bottle_app
WSGIApplicationGroup %{GLOBAL}
WSGIScriptReloading On
Order deny,allow
Allow from all
# Require all granted
</Directory>
ErrorLog /var/log/httpd/errors.log
CustomLog /var/log/httpd/requests.log combined
</VirtualHost>