Sign inSign up

iwfwebsolutions/ci-build-dind

By iwfwebsolutions

•Updated 5 months ago

Pre-built Docker-in-Docker (DinD) image used as a Jenkins build agent at IWF

Image
Developer tools
0

1.2K

iwfwebsolutions/ci-build-dind repository overview

⁠ci-build-dind

Pre-built Docker-in-Docker (DinD) image used as a Jenkins build agent at IWF.

License Contributor Covenant Docker Pulls

Based on docker:dind⁠, with bash, git, openssh-client and ca-certificates pre-installed and the git.iwf.io SSH host key pre-trusted. Built and pushed to Docker Hub by GitHub Actions.

⁠Usage

⁠Pull
docker pull iwfwebsolutions/ci-build-dind:latest
⁠Jenkins (declarative pipeline)
agent {
    docker {
        image 'iwfwebsolutions/ci-build-dind:latest'
        // --privileged: dockerd needs it.
        // -u 0:0: overrides Jenkins's auto-injected -u 1000:1000
        //         (last -u wins) so dockerd runs as root.
        // --entrypoint: overrides Jenkins's auto -u --entrypoint cat;
        //         our script starts dockerd, waits for it, then execs cat,
        //         so steps see a ready `docker` daemon with no extra stage.
        args   '--privileged -u 0:0 --entrypoint /usr/local/bin/jenkins-dind-entrypoint'
        reuseNode true
    }
}

No Start DinD stage is needed in your pipeline — the entrypoint handles startup and readiness.

The entrypoint is also runnable standalone:

docker run --rm --privileged \
  --entrypoint /usr/local/bin/jenkins-dind-entrypoint \
  iwfwebsolutions/ci-build-dind:latest \
  sh -c 'docker info'

⁠Local development

⁠Build
docker build -t ci-build-dind:test ./src

Override the base tag via DOCKER_VERSION (defaults to dind):

docker build --build-arg DOCKER_VERSION=28-dind -t ci-build-dind:28 ./src
⁠Smoke test
docker run --rm --privileged ci-build-dind:test sh -c \
  'git --version && ssh -V && bash --version && grep git.iwf.io /root/.ssh/known_hosts'
⁠Lint
brew install hadolint
hadolint src/Dockerfile

⁠CI / release

Pushes to main (and *.*.* tags) trigger .github/workflows/ci.yml, which builds linux/amd64 + linux/arm64 and pushes to Docker Hub.

Required repository configuration:

  • Variable DOCKERHUB_USERNAME — Docker Hub user/org (e.g. iwfwebsolutions)
  • Variable IMAGE_NAME — full image name (e.g. iwfwebsolutions/ci-build-dind)
  • Secret DOCKERHUB_TOKEN — Docker Hub access token with push rights

Base image is unpinned (docker:dind → latest). Trigger a manual rebuild via the Actions → Continuous Integration → Run workflow button to pick up upstream patches.

⁠Contributing

Please read CONTRIBUTING.md⁠ for details on our code of conduct and the process for submitting pull requests.

⁠Authors

⁠Special thanks for all the people who had helped this project so far

See also the full list of contributors⁠ who participated in this project.

⁠I would like to join this list. How can I help the project?

We're currently looking for contributions for the following:

  • Bug fixes
  • Translations
  • etc...

For more information, please refer to our CONTRIBUTING.md⁠ guide.

⁠License

This project is licensed under the MIT License - see the LICENSE.txt⁠ file for details

⁠Acknowledgments

This project currently uses no third-party libraries or copied code.

Tag summary

Content type

Image

Digest

sha256:54b801b3e…

Size

135.1 MB

Last updated

5 months ago

docker pull iwfwebsolutions/ci-build-dind