GithubHelp home page GithubHelp logo

streamhpc / dockercontainers Goto Github PK

View Code? Open in Web Editor NEW

This project forked from khronosgroup/dockercontainers

0.0 0.0 0.0 86 KB

Docker container specifications which package dependencies for building Khronos documentation and software

License: Apache License 2.0

Shell 30.96% CMake 4.66% Dockerfile 64.37%

dockercontainers's Introduction

DockerContainers

Docker container specifications which package dependencies for building Khronos documentation and software.

Images built from this github repository are pushed to the Dockerhub repository https://hub.docker.com/r/khronosgroup/docker-images.

Structure

Each Dockerfile is named <tag>.Dockerfile where <tag> (e.g. openxr, asciidoctor-spec) matches the tag for that image in the Dockerhub repository (e.g. KhronosGroup/docker-images:rust). A second tag is suffixed with .<date> representing a timestamp when this image was last modified.

Scripts

In general, any additional arguments are forwarded on to docker build except the first if it is "push", so this is how you can pass --no-cache to force a rebuild, etc.

  • Single-image scripts: pass a tag name as the first argument and a version as the second.
    • ./build-one.sh <tag> <date> - Just builds and tags the image locally, does not push to Dockerhub. Use for testing modifications.
    • ./build-one.sh <tag> <date> push - Builds and tags the image locally, then pushes it to Dockerhub. Only run this once you've committed (and ideally, pushed) the corresponding changes to this Git repo.
  • ./build-all.sh - Just calls ./build-one.sh on all the tags listed in it. Use as ./build-all.sh push to push all images to Dockerhub. If you add a new Dockerfile to this repo, add it to this script too.

Container Hashes

We have encountered problems with both gitlab and Github Actions CI not flushing cache when an updated image of the same name is pushed to dockerhub. While using different tags on every push is a possibility, another approach is to use the container SHA256 hash instead of the container name. This can be determined at container build time, or as follows:

$ docker inspect --format='{{index .RepoDigests 0}}' khronosgroup/docker-images:asciidoctor-spec
khronosgroup/docker-images@sha256:1535246a0270e5a118b11ba121ac3c08849782d27afcac28e3859424db659f2f

Using the last line as the image name in CI will pull that specific hash instead of whatever the currently cached version of the underlying image name is. This works in both gitlab and Github Actions.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.