liveBook · Manning

Container registry

As explained in Spring in Action, Sixth Edition

A container registry is a service that stores and distributes container images.

A container registry stores and distributes container images. After Spring Boot builds an image, give it a repository-based tag so DockerHub can receive it. section 18.3

A practical registry workflow is:

  • Build the Spring Boot image with Docker available on the build machine. section 18.3
  • Replace the local library prefix with an organization repository, such as tacocloud/tacocloud:0.0.19-SNAPSHOT. section 18.3
  • Push the tagged image to the registry with Docker. section 18.3

Publishing a TacoCloud image

Configure the Spring Boot build to produce tacocloud/${project.artifactId}:${project.version}, then push the resulting image. Build variables keep the repository tag aligned with the application version. section 18.3

$ mvnw spring-boot:build-image \
    -Dspring-boot.build-image.imageName=tacocloud/tacocloud:0.0.19-SNAPSHOT

Use a Spring Boot Maven command to build an image with a registry-ready repository tag. section 18.3

$ docker push habuma/tacocloud:0.0.19-SNAPSHOT

Push the tagged image to its DockerHub repository. section 18.3

How Spring in Action, Sixth Edition covers it

How deep it goes
Explains image tags, Maven and Gradle configuration, and pushing, but does not detail registry internals.
Examples
Uses the tacocloud repository, versioned image tags, Spring Boot build commands, and docker push.
What it assumes
Assumes Docker is installed and the application can be built into a container image.
What you can do after
Operate/configure a Spring Boot build to create and publish a repository-tagged Docker image.
How it connects
Connects container images with Docker, DockerHub, Spring Boot, Maven, and Gradle.

Also explained in

Compare how 8 books explain container registry →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Spring in Action, Sixth Edition. The section links point to the parts of the book it draws on.