0

I am trying to run a spring boot application with a prerequisite of java 8 and maven (both are installed) properly. while running test:

mvn clean test

it ran completed as SUCCESS and also

mvn spring-boot:run​ completed success

But when I execute the below command locally
curl http://localhost:8080/actuator/info​

connect was refused error with curl 7

I am using CENTOS on GCP and has enabled the traffic for port 8080 in the security in GCP. Can anyone help with this, is there I am missing?

Umesh Kumhar
  • 766
  • 6
  • 14
Monty
  • 19
  • 1
  • 7
  • Check spring boot application logs. Look for the URL and port in which the app is published. – CodeRider Dec 08 '19 at 11:47
  • can you please specify the location or path of logs becuase i have checked 8080 is free no other services are running on that port. – Monty Dec 09 '19 at 16:12

1 Answers1

1

CURL ERROR 7 Failed to connect to Permission denied” error is caused, when for any reason curl request is blocked by some firewall or similar thing.

Please check if this link helps you: How to resolve cURL Error (7): couldn't connect to host?

Also check if your port 8080 is already in use. There may already be running in another process, or a system process may be using the port. To start this server you will need to stop the other process or change the port number(s).

Kum
  • 333
  • 7
  • 20