Giter Site home page Giter Site logo

cloudfoundry-community / jenkins-swarm-boshrelease Goto Github PK

View Code? Open in Web Editor NEW
3.0 44.0 0.0 16 KB

Bosh release for setting up a Jenkins/Swarm cluster with Pipeline and Docker Workflow plugins installed.

License: MIT License

Shell 93.34% HTML 6.66%
bosh-release

jenkins-swarm-boshrelease's Introduction

jenkins-swarm-boshrelease

Build It

This bosh release does not download its blobs from AWS S3. Instead you will need to run the build script to download the blobs before creating the release using the following script.

./build-local.sh help

    USAGE: ./build-local.sh [help | clean-blobs | clean-build | clean-all ]
    
        clean-blobs: force re-download of all blobs
        clean-build: reset dev build number
        clean-all: do both clean-blobs and clean-build

Before you run the build script ensure that you have the Bosh CLI installed and target a Bosh Director.

A 'clean-build' or 'clean-all' build will not only delete you release from Bosh Director but also delete your deployment

Deploy It

You can use the sample manifest file to deploy this release to a Bosh-Lite environment. Make sure that before you set the deployment and deploy, you update the manifest's director_uuid to match you Bosh Director's UUID.

You also need to upload the latest warden stemcell and the docker bosh-release before you deploy using the given sample manifest.

bosh upload stemcell https://bosh.io/d/stemcells/bosh-warden-boshlite-ubuntu-trusty-go_agent
bosh upload release https://bosh.io/d/github.com/cf-platform-eng/docker-boshrelease

To build and deploy simply run.

bosh deployment example-manifests/jenkins-swarm-bosh-lite.yml
./build-local.sh
bosh deploy

Test It

To test simply login to Jenkins using admin/password as the login credentials and create a "pipeline" project. Use the following script to test the pipeline with docker.

node("docker") {
    stage "Parallel Docker Pull"
    def tasks = [:]
    tasks["PullMavenImage"] = {
        docker.image("maven").pull()
    }
    tasks["PullGoLangImage"] = {
        docker.image("golang").pull()
    }
    parallel tasks
    
    stage "Checkout"
    sh "docker run maven bash -c \"echo 'Checkouting the code' && ping -c 20 localhost\""

    stage "Build"
    sh "docker run golang echo 'Building the code'"
}

node("docker") {
    stage "Deployment"
    sh "docker run maven echo 'Deploying the code'"
    
    stage "Integration Tests"
    sh "docker run maven echo 'Integration tests are running'"
}

jenkins-swarm-boshrelease's People

Contributors

mevansam avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  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.