GithubHelp home page GithubHelp logo

jasiek / ci-docker-image Goto Github PK

View Code? Open in Web Editor NEW

This project forked from dokku/ci-docker-image

0.0 1.0 0.0 41 KB

A Docker Image meant for use with CI/CD pipelines

License: MIT License

Dockerfile 2.10% Shell 97.90%

ci-docker-image's Introduction

ci-docker-image

A Docker image meant for use with CI/CD pipelines

Supported CI Systems

Assuming a Docker image can be run as a CI task with environment variables injected, the following CI systems will have their variables automatically detected:

Usage

This image provides two binaries for external usage:

  • dokku-deploy: Triggers an app deploy at the configured GIT_REMOTE_URL
  • dokku-unlock: Unlocks deploys for an app at the configured GIT_REMOTE_URL

To run either binary, the following docker command can be used from a directory containing a non-shallow clone of the repository being deployed:

# where the `.env` file contains `GIT_REMOTE_URL` and `SSH_PRIVATE_KEY`

# deploy
docker run --rm -v="$PWD:/app" --env-file=.env dokku/ci-docker-image dokku-deploy

# unlock
docker run --rm -v="$PWD:/app" --env-file=.env dokku/ci-docker-image dokku-unlock

Configuration

The following environment variables are supported:

  • BRANCH:
    • description: The branch to deploy when pushing to Dokku
    • required: false
    • default: ''master
  • CI_BRANCH_NAME
    • description: The branch name that triggered the deploy. Interpolated if unavailable.
    • required: false
    • default: ''
  • CI_COMMIT
    • description: The commit sha that will be pushed. Interpolated if unavailable.
    • required: false
    • default: ''
  • COMMAND:
    • description: The command to run for the action
    • required: false
    • default: 'deploy'
  • GIT_PUSH_FLAGS:
    • description: The dokku app's git repository url (in SSH format)
    • required: true
  • GIT_REMOTE_URL:
    • description: A string containing a set of flags to set on push
    • required: false
  • REVIEW_APP_NAME:
    • description: The name of the review app to create or destroy
    • required: false
    • default: 'review-$APP_NAME-$CI_BRANCH_NAME'
  • SSH_HOST_KEY:
    • description: The results of running ssh-keyscan -t rsa $HOST
    • required: false
    • default: ''
  • SSH_PRIVATE_KEY:
    • description: A private SSH key that has push acces to your Dokku instance
    • required: true

Building

docker build dokku/ci-docker-image .

ci-docker-image's People

Contributors

badsyntax avatar jasiek avatar josegonzalez avatar nerg4l avatar

Watchers

 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.