Search code examples
amazon-web-servicesamazon-ec2dnsportamazon-route53

Connecting Route 53 to EC2 and port


I'm having trouble connecting Route 53 to an EC2 with an app running on the 8080 port. Currently, I can hit and use the app using http://<EC2 name>:8080/<endpoint path>, but I obviously want to hit it with a domain name instead.

I created a host zone .com, created a record, used record type A and set the ip as the ipv 4 provided by the EC2. I then copied the four ns- route traffic names across to the nameservers in registered domain. Unfortunately, when I hit www.<domain name>/<endpoint path> I get 'did not match any documents'.

Is this something I'm missing when setting up the route 53 or is it an issue to do with the port?

Any help would be gratefully received.


Solution

  • Simple enough in the end, I just used sudo java -Dserver.port=80 -jar .jar & No setting up the code differently, just setting it to use port 80. Also found out I had to use sudo, otherwise you get a permission denied when allocating to the root.