Jupyter single-user instance
This repository has been archived on 2025-07-06. You can view files and clone it, but cannot push or open issues or pull requests.
Go to file
2024-12-20 20:42:33 +11:00
.gitea/workflows feat: use runnerdnd image 2024-12-01 13:18:27 +11:00
release feat: enable multirelease 2024-12-20 20:39:03 +11:00
Makefile feat: enable multirelease 2024-12-20 20:39:03 +11:00
README.md feat: first commit of jupyterinstnace 2024-11-10 12:39:55 +11:00

Docker Image Build: Almalinux Jupyterinstance

This project provides a reproducible Docker image build process for almalinux:8.10, with custom YUM repository configurations and package installations. The build is automated using a Makefile and managed via CI tasks to ensure consistent and reliable Docker image builds.

Makefile Overview

The Makefile provides several targets to automate building, tagging, and pushing Docker images. The Docker image is tagged with the current Git commit hash, the current date, and a latest tag for easy reference.

Makefile Targets

Build the Docker Image

To build the Docker image without tags:

make build

This will use the docker build command with --network=host to build the image with the name `git.query.consul/unkin/almalinux8-jupyterinstance.

Tag the Docker Image

To tag the Docker image with the Git commit hash, the current date, and a latest tag:

make tag

This will add three tags to the image:

  • git.query.consul/unkin/almalinux8-jupyterinstance:<GIT_COMMIT>
  • git.query.consul/unkin/almalinux8-jupyterinstance:<DATE_TAG>
  • git.query.consul/unkin/almalinux8-jupyterinstance:latest

Push the Docker Image

To push the tagged Docker images to the registry:

make push

Note

: The push command is currently commented out for safety. To enable pushing, remove the comment (#) from the docker push lines in the push target.

Clean Up

To clean up any dangling Docker images:

make clean

This will remove any dangling (unused) Docker images using docker image prune -f.

Default Target

The default target is build. So running:

make

is equivalent to running make build.

Development and Testing

To test or develop with this Makefile, follow these steps:

  1. Clone the repository and navigate to the project directory:

    git clone https://git.query.consul/unkin/docker-almalinux-jupyterinstance.git
    cd docker-almalinux-jupyterinstance
    
  2. Build the Docker image using the build target:

    make build
    
  3. Tag the image with the commit hash, date, and latest tag:

    make tag
    
  4. (Optional) Modify the push target to enable pushing the image to your Docker registry: Uncomment the lines in the push target:

    docker push $(REGISTRY)/$(OWNER)/$(IMAGE_NAME):$(GIT_COMMIT)
    docker push $(REGISTRY)/$(OWNER)/$(IMAGE_NAME):$(DATE_TAG)
    docker push $(REGISTRY)/$(OWNER)/$(IMAGE_NAME):latest
    
  5. Test your changes locally by running the clean target:

    make clean