Unable to find Virtual Host listening on Port 80

My domain is: inverserobotics.in
Hosting: AWS EC2 Instance Ubuntu 18.04 LTS
Control Panel: Vesta

I followed the following guide

My HTTP website is running Apache on Ubuntu 18.04 LTS (bionic)

I added Letsencrypt support in Vesta Control Panel under inverserobotics.in domain name

I ran this command:
apachectl -t -D DUMP_VHOSTS

It produced this output:
Screenshot from 2020-06-08 19-40-24

I ran this command:
nano /etc/hosts

It produced this output:
127.0.0.0 localhost

Following Files are available under /home/admin
.conf , .pem , .key

Pls help me to sort the issues

Hi @mallikarjun

that’s a port 8080 vHost. Not the required port 80 vHost.

And don’t use 172.31.41.166:80, that may not work. Use *:80.

1 Like

I created inverserobotics.in.conf file in /etc/apache2/sites-available

Inside inverserobotics.in.conf is,
Screenshot from 2020-06-09 11-42-45

I ran this command: a2ensite inverserobotics.in.conf
It produced this Output: inverserobotics.in.conf is enabled pls restart apache

I ran this command: systemctl restart apache2

Rebooted the apache server

I ran this command: /etc/hosts
It produced this output: 127.0.0.1 localhost

inverserobotics.in is not visible

Checked your domain - https://check-your-website.server-daten.de/?q=inverserobotics.in - I don't understand your questions.

You have a working certificate with both domain names.

CN=inverserobotics.in
	08.06.2020
	06.09.2020
expires in 89 days	inverserobotics.in, www.inverserobotics.in - 2 entries

both connections use that certificate. So your https configuration is ok.

Only problem: You don't have a redirect http -> https and your nameserver configuration is buggy. ns1.domain.tld isn't a name server.

VestaCP has an own, working Letsencrypt client and support. So you should never mix that with a raw certbot.

You are absolutely correct. I have a working Certificate (I checked under my domain inverserobotics.in Vesta Control Panel).

How to redirect Http to Https?

Domain Purchase: Godaddy
Domain Hosting: AWS EC2 via Vesta Control

I followed the following guide and created .htaccess file under root public_html

Screenshot from 2020-06-09 16-20-06

But still not working

I don't know how VestaCP works. But if VestaCP controls the vHost definitions, you should find a solution in VestaCP, not with additional things.

1 Like

I don’t know what’s happening…

When I open the website in Mobile I can see a lock icon next to my website
inverserobotics.in
https://inverserobotics.in
www.inverserobotics.in
https://www.inverserobotics.in

But when I open in Laptop/Desktop I don’t see Lock Icon and In laptop www.inverserobotics.in the website not loading at all

That's your missing redirect http -> https.

2 Likes

Looks like the redirects are configured now! :smiley:
Rip

2 Likes

Thank You.

Your valuable suggestions helped me to learn a lot & fix few issues.

Don’t know what happened but it’s working…

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