79569244

Date: 2025-04-11 15:48:29
Score: 1
Natty:
Report link

The error occurs because there is no Elasticsearch instance running in the GitHub Actions runner. To run your application in the pipeline, you need to provide a valid and accessible Elasticsearch URL—either by spinning up a service within the pipeline or pointing to an external instance.

That said, running the actual JAR file in your CI pipeline is generally not considered best practice. If your goal is to verify that the application works correctly, it's better to write automated tests and use tools like Testcontainers to spin up temporary instances of Elasticsearch and other dependencies during the test phase. This approach provides more reliable, repeatable, and isolated test environments.

Reasons:
  • Long answer (-0.5):
  • No code block (0.5):
  • Low reputation (1):
Posted by: Muhammad Khosravi