Skip to content

Commit

Permalink
initial
Browse files Browse the repository at this point in the history
  • Loading branch information
skaegi committed Apr 14, 2016
1 parent 253f85b commit 4d76c12
Show file tree
Hide file tree
Showing 7 changed files with 238 additions and 1 deletion.
78 changes: 78 additions & 0 deletions .bluemix/deploy.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Hello World Deploy Stage",
"description": "hello-world simple toolchain",
"longDescription": "The Delivery Pipeline for Devops Services allows you to automate your continuous deployment setup hello-world.",
"type": "object",
"properties": {
"prod-region": {
"description": "The bluemix region",
"type": "string"
},
"prod-organization": {
"description": "The bluemix org",
"type": "string"
},
"prod-space": {
"description": "The bluemix space",
"type": "string"
},
"hello-world-name": {
"description": "hello world app name",
"type": "string"
}
},
"required": ["prod-region", "prod-organization", "prod-space", "hello-world-name"],
"form": [
{
"type": "validator",
"url": "/develop/setup/bm-helper/helper.html"
},
{
"type": "text",
"readonly": false,
"title": "Hello World App Name",
"key": "hello-world-name"
},
{
"type": "table",
"columnCount": 4,
"widths": ["15%", "28%", "28%", "28%"],
"items": [
{
"type": "label",
"title": ""
},
{
"type": "label",
"title": "Region"
},
{
"type": "label",
"title": "Organization"
},
{
"type": "label",
"title": "Space"
},
{
"type": "label",
"title": "Prod Stage"
},
{
"type": "select",
"key": "prod-region"
},
{
"type": "select",
"key": "prod-organization"
},
{
"type": "select",
"key": "prod-space",
"readonly": false
}
]
}
]
}
53 changes: 53 additions & 0 deletions .bluemix/github.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Hello-world Deploy Stage",
"description": "GitHub Schema hello-world",
"longDescription": "The GitHub Service allows you to create or use an existing GitHub repository to store your source code.",
"type": "object",
"properties": {
"hello-world-repo_name": {
"type": "string"
},
"hello-world-repo_url": {
"type": "string"
}
},
"required": ["hello-world-repo_name", "hello-world-repo_url"],
"form": [
{
"type": "validator",
"url": "/develop/setup/bm-helper/custom_github_helper.html"
},
{
"type": "table",
"columnCount": 3,
"widths": ["47%", "6%", "47%"],
"items": [
{
"type": "label",
"title": "Source Repository"
},
{
"type": "label",
"title": ""
},
{
"type": "label",
"title": "Target Repository"
},
{
"type": "text",
"key": "hello-world-repo_url"
},
{
"type": "icon",
"iconType": "right_arrow"
},
{
"type": "text",
"key": "hello-world-repo_name"
}
]
}
]
}
42 changes: 42 additions & 0 deletions .bluemix/hello-world.pipeline.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
---
stages:
- name: BUILD
inputs:
- type: git
branch: master
service: ${HELLO_WORLD_REPO}
triggers:
- type: commit
jobs:
- name: Build
type: builder
- name: DEPLOY
inputs:
- type: job
stage: BUILD
job: Build
triggers:
- type: stage
properties:
- name: CF_APP_NAME
value: undefined
type: text
- name: APP_URL
value: undefined
type: text
jobs:
- name: Deploy
type: deployer
target:
region_id: ${PROD_REGION_ID}
organization: ${PROD_ORG_NAME}
space: ${PROD_SPACE_NAME}
application: ${CF_APP_NAME}
script: |
#!/bin/bash
# Push app
export CF_APP_NAME="$CF_APP"
cf push "${CF_APP_NAME}"
export APP_URL=http://$(cf app $CF_APP_NAME | grep urls: | awk '{print $2}')
# View logs
#cf logs "${CF_APP_NAME}" --recent
Loading

0 comments on commit 4d76c12

Please sign in to comment.