Skip to content

Commit 22fe8a6

Browse files
authored
Create README.md
1 parent cbb700a commit 22fe8a6

File tree

1 file changed

+35
-0
lines changed

1 file changed

+35
-0
lines changed

groovy-onbuild/README.md

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
This project contains Dockerfile that creates a base image to run Spring Boot applications.
2+
3+
This is not an official Google product.
4+
5+
How to use this image
6+
=====================
7+
8+
Groovy Applications
9+
-------------------
10+
Create a Dockerfile in your project directory:
11+
12+
FROM saturnism/spring-boot:1.2.3-jdk-8-groovy-2.4.3
13+
ADD . $SRC_DIR
14+
15+
You can then build and run the image:
16+
17+
docker build -t myapp
18+
docker run -ti myapp
19+
20+
You'll notice that everytime the container starts, it will resolve all the dependencies.
21+
To avoid this, you can also pre-compile your Groovy application using the `onbuild` image.
22+
23+
In the Dockerfile, use:
24+
25+
FROM saturnism/spring-boot:1.2.3jdk-8-groovy-2.4.3-onbuild
26+
27+
You can then build and run the image just like the previous method:
28+
29+
docker build -t myapp
30+
docker run -ti myapp
31+
32+
33+
Examples
34+
--------
35+
You can find examples under the [Examples](examples/) directory.

0 commit comments

Comments
 (0)