Giter Site home page Giter Site logo

cr-pipeline-scripts's Introduction

cr-pipeline-scripts

Scripts to build and deploy CR using the pipeline.

To use the blue-green deployment scripts:

  • Make sure the Application Name field is set on the Pipeline stage so that CF_APP will be defined.
  • All Pipeline stage environment variables will be set as environment variables in the CF app.
  • To bind services to the CF app, put the service names in and environment variables named SERVICE_NAMES separated with commas and no spaces.
  • Basic testing to check if the TEST_PATH returns a 200 status is dones. You may set TEST_STATUS_PASS to check that the JSON returned has a 'PASS' status or TEST_STATUS_NUMERIC to check that the JSON status is 0 and not 1.
#!/bin/bash
export PATH=/opt/IBM/node-v6.2.2/bin:$PATH

export DOMAIN=mybluemix.net
export TEST_PATH=api/v1/status
export INSTANCES=1
export MEMORY=256M

git clone --depth=1 https://github.com/rws-github/cr-pipeline-scripts.git ../cr-pipeline-scripts
chmod +x ../cr-pipeline-scripts/blue-green/*.sh

. ../cr-pipeline-scripts/blue-green/all.sh

To use the Cloudant design document init scripts:

#!/bin/bash
export PATH=/opt/IBM/node-v6.2.2/bin:$PATH

export CLOUDANT_URL=...
export CLOUDANT_DB=...
export DESIGN_DIR=`pwd`/design

git clone --depth=1 https://github.com/rws-github/cr-pipeline-scripts.git ../cr-pipeline-scripts
chmod +x ../cr-pipeline-scripts/cloudant/*.sh

# If you want to run a seed script to:
# export CLOUDANT_SEED=`pwd`/seed.js
../cr-pipeline-scripts/cloudant/init.sh

The two above combined:

#!/bin/bash
export PATH=/opt/IBM/node-v6.2.2/bin:$PATH

export DOMAIN=mybluemix.net
export TEST_PATH=api/v1/status
export INSTANCES=1
export MEMORY=256M
export DESIGN_DIR=`pwd`/design

git clone --depth=1 https://github.com/rws-github/cr-pipeline-scripts.git ../cr-pipeline-scripts
chmod +x ../cr-pipeline-scripts/blue-green/*.sh
chmod +x ../cr-pipeline-scripts/cloudant/*.sh

../cr-pipeline-scripts/cloudant/init.sh
. ../cr-pipeline-scripts/blue-green/all.sh

cr-pipeline-scripts's People

Contributors

crjenkins89 avatar gferreri avatar rws-github avatar

Watchers

 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.