I have a domain on Godaddy https://touchbasic.app It was hosted on HostGator where everything worked and was easy to set up. I can't figure out how to make my EC2 server host it so I can get rid of HostGator. I get ERR_CONNECTION_TIMED_OUT in when I go to my domain in my browser.
I'm hosting non-https domains just fine on my EC2 server. The problems is ".app" domains require https, and on EC2 that is super super complicated to set up hosting for. I've spent days on this. I've posted in the ec2 forums but it seems that people rarely get responses there.
Do I have to use a load balancer? I don't want one. Does it do anything if I only have 1 server? Which tutorial should I follow? I've tried all of them already and restarted several times.
I've added to httpd.conf:
<VirtualHost *:443>
ServerAdmin [email protected]
DocumentRoot "/var/www/html/touchbasicdotapp"
ServerName touchbasic.app
ErrorLog "logs/touchbasic.app-error_log"
CustomLog "logs/touchbasic.app-access_log" common
</VirtualHost>
and did httpd restart.
I added rules to my security group:
HTTPS
TCP
443
0.0.0.0/0
HTTPS
TCP
443
::/0
I created the folder with index.html in it /var/www/html/touchbasicdotapp
I've created a Hosted Zone in Route 53, which gave me 4 nameservers, which I set in Godaddy.
I created an A record with the IP of my server. That did not work so I made a Load Balancer. I made a certificate for my domain and added a CNAME with that in it. I added a SOA record with my load balancer in it. It has a listener with ELBSecurityPolicy-2016-08 and SSL Certificate. Now the error is 502 Bad Gateway. When I go to load balancer targets, it says status unhealthy (health checks failed). I can't find any relevant log files. Do I need to set up S3 just to have log files?
Is there anyone I can pay to set this up for me? If I upgrade my account will Amazon set this up for me? Do I need a very deep knowledge of servers to host a very simple .app website on amazon?
You do not need to manage SSL at the instance level as LB do that for you. So better to go with this approach.
Update apache config to listen of port 80
and do restart.
<VirtualHost *:80>
ServerAdmin [email protected]
DocumentRoot "/var/www/html/touchbasicdotapp"
ServerName touchbasic.app
ErrorLog "logs/touchbasic.app-error_log"
CustomLog "logs/touchbasic.app-access_log" common
</VirtualHost>