Book Image

Developing with Docker

By : Jaroslaw Krochmalski, Jarosław Krochmalski
Book Image

Developing with Docker

By: Jaroslaw Krochmalski, Jarosław Krochmalski

Overview of this book

This fast-paced practical guide will get you up and running with Docker. Using Docker, you will be able to build, ship, and run many distributed applications in real time. You will start with quickly installing Docker and start working with images and containers. We will present different types of containers and their applications, and show you how to find and build images. You will learn how you can contribute to the image repository by publishing different images. This will familiarize you with the image building process and you will be able to successfully run your programs within containers. By finishing this book, you will be well equipped in deploying your applications using Docker and will have a clear understanding of concepts, techniques, and practical methods to get it running in production systems.
Table of Contents (16 chapters)
Developing with Docker
Credits
About the Author
About the Reviewer
www.PacktPub.com
Preface

Using Docker with Maven


If you develop in Java, you probably know Maven. It's used widely to build Java applications or libraries. The Maven's build process uses the concept of an artifact. An artifact is a file, usually a JAR (containing Java libraries or application) or WAR/EAR, which is a Java web application. The artifacts are deployed to a Maven repository. A Maven build produces one or more artifacts and each artifact has a group ID (usually a reversed domain name, such as com.example.foo), an artifact ID (just a name), and a version string. The three together uniquely identify the artifact. Your application dependencies are also specified as artifacts.You already know Docker pretty well, so you could probably imagine what a useful Maven plug in for Docker should do. It should allow to:

  • Pull images from the registry

  • Build container images

  • Start containers

  • Optionally link containers

  • Expose the needed ports (useful for integration tests)

  • Push images to the registry

Including Docker in your...