Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

Using Docker to Build Code | AEM Community Blog Seeding




Using Docker to Build Code by Max Barrass


Using Docker to Build Code

When you have been working for a long time on a codebase, you don’t tend to test if your code can be compiled on other machines. Most of the time, it means that it won’t. But when you have Docker on your side, your dispair would be a one short docker command line deep.

Using Docker to build your code is so easy even your friend will think you are cool when you tell them about it. The most amazing thing that you don’t even need to write any Docker images, there are so many ready-to-go buildpack containers out there you can easily pick up something that you need.

Here is an example of a container we use to do pipeline build and its very suitable for compiling your project on your local desktop. This container is a Centos 7 Jave Build Pack which means that it comes preconfigured with a majority of tools that are needed to compile our projects.

This container comes with Jave, NPM and RVM, and you can take a look at the contents of the dockerfile.

In power Shell:

docker run -it -v ${PWD}:/build/source -v ${HOME}/.m2:/build/.m2 --net=host aemdesign/centos-java-buildpack /bin/bash --login
In Bash:

docker run -it -v `pwd`:/build/source -v ${HOME}/.m2:/build/.m2 --net=host aemdesign/centos-java-buildpack /bin/bash --login

Read Full Blog

Using Docker to Build Code


Please use this thread to ask the related questions.


Topics help categorize Community content and increase your ability to discover relevant content.

0 Replies