drogo
October 25, 2022, 6:15am
1
Followed steps from community
Hello,
I am trying to run a Java SpringBoot application (Rest API) on Render with Web Services and Docker, The service needs to be public accessible that is why I am using Web Services. But when I try to deploy it to Render the deployment keeps failing
Dockerfile
#
# Build stage
#
FROM maven:3.6.0-jdk-11-slim AS build
COPY src /home/app/src
COPY pom.xml /home/app
RUN mvn -f /home/app/pom.xml clean package
#
# Package stage
#
FROM openjdk:11-jre-slim
COPY --from=build /home/app/target/Falcon-…
#
# Build stage
#
FROM maven:3.6.0-jdk-11-slim AS build
COPY src /home/app/src
COPY pom.xml /home/app
RUN mvn -f /home/app/pom.xml clean package
#
# Package stage
#
FROM openjdk:11-jre-slim
COPY --from=build /home/app/target/Falcon-0.0.1.jar /usr/local/lib/falcon.jar
EXPOSE 8080
ENTRYPOINT ["java","-jar","/usr/local/lib/falcon.jar"]
But, getting an error
error: failed to solve: process "/bin/sh -c mvn -f /home/app/pom.xml clean package" did not complete successfully: exit code: 1
Any ideas? thanks
al_ps
October 25, 2022, 9:00am
2
Hi there,
Thanks for reaching out.
I would expect there are more deploy logs which may shed some light on the actual issue.
If you could share some examples of the issue you are experiencing that may help us troubleshoot it with you, e.g. further logs/errors/output (look for error reasons), service name/ID, etc. If you don’t want to share these details on the community forum, please feel free to raise a ticket with support@render.com
Thanks
Alan
drogo
October 29, 2022, 1:00am
3
Figured it was my JUnit test cases expecting environment variable. Thanks for your response
system
Closed
November 28, 2022, 1:01am
4
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.