GithubHelp home page GithubHelp logo

isabella232 / dockerfile-wizard Goto Github PK

View Code? Open in Web Editor NEW

This project forked from circleci-archived/dockerfile-wizard

0.0 0.0 0.0 588 KB

Use CircleCI to build custom Docker images with combinations of common languages/dependencies

Shell 41.32% Makefile 0.87% Perl 57.81%

dockerfile-wizard's Introduction

CircleCI Dockerfile Wizard

Easily build Docker images with different versions/combinations of common languages/dependencies, for use on CircleCI.

Prerequisites

Usage

1. Fork this repository and start building it on CircleCI:

Setup Project

2. Add your Docker Hub username (DOCKER_USERNAME) and password (DOCKER_PASSWORD) to CircleCI, either as project-specific environment variables (shown below), or as resources in your org-global (default) Context

Environment Variables

3. Clone your fork of the project onto your computer

4. Enter the cloned dockerfile-wizard directory and run make ready to prepare the config.yml file for building Docker images on CircleCI

5. Run make setup in the cloned directory, or else manually add the versions/dependencies that you need to .circleci/config.yml as specified in the image_config section

6. Commit and push your changes

Once the build has finished, your image will be available at http://hub.docker.com/r/DOCKER_USERNAME/IMAGE_NAME and can be used in other projects building on CircleCI (or anywhere else!). The Dockerfile for your image will be stored as an artifact in this project's build job.

To use the Dockerfile Wizard again, run make reset in the cloned directory, then repeat steps 4-6.

How it works

  1. The setup script adds your requested version information to the config.yml file as environment variables
  2. The generate.sh script runs on CircleCI and generates a Dockerfile based on those environment variables
  3. CircleCI builds your Docker image from the generated Dockerfile, deploys it using your Docker credentials, and then tests your image using Bats, which we install in every Docker image built via this repository

Notes

  • The portions of this repository that run on your local computer are intended for Linux/macOS operating systems; they may not work on Windows
  • This repository has not been tested with every possible permutation of versions/dependencies, and you may encounter errors with some combinations of various languages/tools. If your build job fails, check its docker build step—there's likely a compilation error with a particular version of Ruby, Node, or Python.
  • Thanks to jmason for the tap-to-junit script!
  • Feedback/questions/bugs welcome!
  • Want to do all this yourself? Check out our video on creating custom Docker images for CircleCI

To-do

  • Add PHP support
  • Add support for other container registries

dockerfile-wizard's People

Contributors

iynere avatar ryanwohara avatar aderyabin avatar fgblomqvist avatar

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.