How to run with buildkit - Islandora-Devops/isle-dc GitHub Wiki

DRAFT

This is a draft intended for feedback.

buildkit

Build it where ever you want. It stores the containers in your local machine's Docker images cache.

"Each instruction in your Dockerfile results in a new image layer being created and added to your local image cache. That image then becomes the parent for the image created by the next instruction"

In other words, the buildkit creates several new Docker images on top of the ones it had already downloaded from Dockerhub. These new docker images are cached locally. When Isle-dc spins up, it will use the images matching the repository and tag specified in the .env file to create the containers.

The repository is likely going to be set to either islandora or local.

  • islandora uses the image from Dockerhub.
  • local uses the locally cached docker images. It fetches the Dockerhub image if buildkit hasn't already created a new local version.

Buildkit uses Gradle and allows the user to build custom Docker images and cache them locally. Example: ./gradlew build --continuous. See isle-buildkit for more information.

.env file

Some changes are needed to the .env file to get it to look at the local Docker image cache. If there is no .env file, copy the sample.env file to .env and modify that.

Inside of the isle-dc directory is a "sample.env" file. Copy it to a file named ".env" if you haven't already and change these values.

REPOSITORY=local
TAG=latest

Now that the .env file, pull in these env changes. Run the make env if you already have a running isle-dc. Otherwise, build with make up or local.

make up

After updating buildkit

After updating buildkit you may need to run make up again to get the changes to load into the active containers.