Add Api endpoint and cloud build info

beautify Dockerfile
This commit is contained in:
Marcel Schwarz 2020-03-16 03:04:40 +01:00
parent 61450da84a
commit 20559e6be8
3 changed files with 13 additions and 2 deletions

View File

@ -7,4 +7,4 @@ FROM openjdk:13-jdk-alpine
WORKDIR /root
COPY --from=build /root/build/libs/*.jar app.jar
EXPOSE 80
ENTRYPOINT ["java","-jar","app.jar"]
ENTRYPOINT ["java", "-jar", "app.jar"]

View File

@ -1 +1,7 @@
passwort-generator
#How to Deploy on Cloud run
https://cloud.google.com/run/docs/quickstarts/build-and-deploy
```
gcloud builds submit --tag gcr.io/[PROJECT-ID]/pwgen
```

View File

@ -8,7 +8,12 @@ public class DefaultController {
@RequestMapping("/")
public String index() {
return "Greetings from Spring Boot, also from a Docker Container!";
return "Greetings from Spring Boot, also from a Docker Container from Port 80!";
}
@RequestMapping("/api")
public String standard() {
return "password";
}
}