An HTTP triggered Java Cloud Run template.
Compile:
mvn compile
Run:
mvn spring-boot:run
...
2023-02-24 12:56:32.993 INFO 33811 --- [ main] o.s.b.w.embedded.tomcat.TomcatWebServer : Tomcat started on port(s): 8080 (http) with context path ''
2023-02-24 12:56:33.002 INFO 33811 --- [ main] run.HelloHttpApplication : Started HelloHttpApplication in 1.555 seconds (JVM running for 1.821)
Inside the scripts folder, run test_local.sh to test locally:
./test_local.sh
Hello World!
Run setup.sh to enable required services:
./setup.sh
Run deploy.sh to deploy to Google Cloud:
./deploy.sh
Run test_cloud.sh to test the service in Google Cloud:
./test_cloud.sh
When you're done, you can cleanup created resources:
./cleanup.sh