[Solved] AWS EC2 AMI setup

I can’t access the server from public IP.

On a new Image,
curl http://localhost
I can see a page titles Mattermost - Signup

After changing the following in the file /etc/nginx/sites-available/mattermost

I’ve changed proxy_pass http://10.10.10.2:8065;
by my AWS EC2 server public IP > proxy_pass http://xxx.xxx.xxx.xxx:8065;

I’ve done a
sudo service nginx restart

when I type curl http://xxx.xxx.xxx.xxx
I get curl: (7) Failed to connect to xxx.xxx.xxx.xxx port 80: Connection timed out

To make sure in Security Groups, I’ve opened all ports from all traffic. (It doesn’t solve my problem)

So I don’t know what I’m missing here.
Any ideas ?

Ok false alert,

I could’nt telnet my ip

telnet yourinstancepublicip 80

So I tried to look into firewalls etc, but it wouldn’t solve my issue.

Then I realized that the Security Group was not “attached” to my instance…

If someone has the same problem as me.
Go to instance, Acions > Networking > Change Security Groups
Then select your security group and Voilà!

I on the contrary had the opposite problem, I couldn’t access the fake ip, when used proxies. It’s weird.