-
Notifications
You must be signed in to change notification settings - Fork 204
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added Tier based deployment support, minikube support, Helm unit test…
… cases, Auto-publish to bintray (#26) * Added Tier based deployment support * Minikube support * Helm unit test cases * Auto-publish to bintray
- Loading branch information
1 parent
b67d80d
commit 754066f
Showing
104 changed files
with
5,453 additions
and
525 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,53 +1,85 @@ | ||
--- | ||
language: python | ||
env: | ||
global: | ||
- HELM_URL=https://storage.googleapis.com/kubernetes-helm | ||
- HELM_TGZ=helm-v2.11.0-linux-amd64.tar.gz | ||
- HELM_TGZ=helm-v2.14.0-linux-amd64.tar.gz | ||
- YAMLLINT_VERSION=1.15.0 | ||
install: | ||
# Install Helm | ||
- wget -q ${HELM_URL}/${HELM_TGZ} | ||
- tar xzfv ${HELM_TGZ} | ||
- PATH=`pwd`/linux-amd64/:$PATH | ||
- helm init --client-only | ||
# Install pip deps | ||
# Install YamlLint | ||
- sudo pip install yamllint=="${YAMLLINT_VERSION}" | ||
# Install Go | ||
- wget -c https://storage.googleapis.com/golang/go1.7.3.linux-amd64.tar.gz | ||
- sudo tar -C /usr/local -xvzf go1.7.3.linux-amd64.tar.gz | ||
- export PATH=$PATH:/usr/local/go/bin | ||
script: | ||
# Check YAML styling | ||
- yamllint -c .yamllint.yml -s $(find . -type f -name "Chart.yaml") | ||
- yamllint -c .yamllint.yml -s $(find . -type f -name "values.yaml") | ||
- yamllint -c .yamllint.yml -s $(find . -type f -name "values*.yaml") | ||
# Now load the helm dependencies | ||
- make dependencies | ||
# Run Helm lint | ||
- helm lint ./charts/pega | ||
- helm lint ./charts/pega | ||
- helm lint ./charts/addons | ||
# Run GO helm unit tests | ||
- mkdir $TRAVIS_BUILD_DIR/terratest/bin | ||
- export GOPATH=$TRAVIS_BUILD_DIR/terratest | ||
- curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh | ||
- export PATH=$PATH:$TRAVIS_BUILD_DIR/terratest/bin | ||
- cd terratest/src/test | ||
- dep ensure | ||
- go test deploy_test.go common_utility.go deployment_utility.go | ||
- go test install_test.go common_utility.go installer_utility.go | ||
- go test install_deploy_test.go common_utility.go deployment_utility.go installer_utility.go | ||
- go test upgrade_test.go common_utility.go installer_utility.go | ||
- go test upgrade_deploy_test.go common_utility.go deployment_utility.go installer_utility.go | ||
- go test aks_deploy_test.go common_utility.go deployment_utility.go installer_utility.go | ||
- go test eks_deploy_test.go common_utility.go deployment_utility.go | ||
- go test openshift_test.go common_utility.go deployment_utility.go | ||
- go test invalidAction_test.go | ||
- cd $TRAVIS_BUILD_DIR | ||
- chmod 777 before_deploy.sh | ||
before_deploy: | ||
- ./before_deploy.sh | ||
- make examples | ||
deploy: | ||
provider: releases | ||
api_key: | ||
secure: > | ||
GuZqxcgBOueUOJWg6t5NaCTIssfkptgdAjwyWm/6SaVXqs9Kdgy | ||
EawtYSu0WLh815qGmuxgVjMbvvkAvtbBXanKH+BheRl1cQjYnza | ||
XJlL+Oa/xxzCqz1n4txqtDMR7l/loqrMTzCRe2bZ806z3+uXpXh | ||
CO12+LwvMDJAAddDkX+2wRE240/1f/0lVlZ2lNzgBitC63jAf1H | ||
ml3/KrgHsTYvNB5M6qKn8C24DcC6PMe012K3hL0O+F+er9Mb39R | ||
FcSLTjF/6AiLvpK4oDAg8sBgciXVq0FPhCXvjbINGB/AY7jM5Ql | ||
0A6ngngZjsjefn+NbtZ3aK230h2m0XM+dN7FJCbtRQeqvczcwRT | ||
/wpDimpzFR0rf/NdXV4G+UZYI6a3bjqKYP5IPN8BbzVo8KzlbGW | ||
JeJLV40gW7EbdyT57R2dNp46I17c1KL8atQH97n3yv9d9ZaC87O | ||
6tOohLmue7L3lKxPDpY60VFna5BjJwvrhW4gvsd11Ko4c39FSu8 | ||
ogBSZ6E1EOlmVZDX+cBjuw4dGihcrHqWW5V3k2X/ksAKb+4A74g | ||
AG8pCr/ifPEj9kTWb71IIF5RHkD6JqeGJdKaWFHDpWlYhKNTLRt | ||
3gmcgdLmM5MN9A5khwBzPYiF5oaWT1COxh/Rjdz5V0+jUvyRvc9 | ||
a/rvc6hM6quXSmlAwA0U= | ||
file: | ||
- pega-kubernetes-example.tar.gz | ||
- pega-openshift-example.tar.gz | ||
- pega-azure-aks-example.tar.gz | ||
- pega-aws-eks-example.tar.gz | ||
- pega-google-gke-example.tar.gz | ||
- pega-pivotal-pks-example.tar.gz | ||
skip_cleanup: true | ||
on: | ||
repo: pegasystems/pega-helm-charts | ||
tags: true | ||
- provider: releases | ||
api_key: | ||
secure: > | ||
GuZqxcgBOueUOJWg6t5NaCTIssfkptgdAjwyWm/6SaVXqs9Kdgy | ||
EawtYSu0WLh815qGmuxgVjMbvvkAvtbBXanKH+BheRl1cQjYnza | ||
XJlL+Oa/xxzCqz1n4txqtDMR7l/loqrMTzCRe2bZ806z3+uXpXh | ||
CO12+LwvMDJAAddDkX+2wRE240/1f/0lVlZ2lNzgBitC63jAf1H | ||
ml3/KrgHsTYvNB5M6qKn8C24DcC6PMe012K3hL0O+F+er9Mb39R | ||
FcSLTjF/6AiLvpK4oDAg8sBgciXVq0FPhCXvjbINGB/AY7jM5Ql | ||
0A6ngngZjsjefn+NbtZ3aK230h2m0XM+dN7FJCbtRQeqvczcwRT | ||
/wpDimpzFR0rf/NdXV4G+UZYI6a3bjqKYP5IPN8BbzVo8KzlbGW | ||
JeJLV40gW7EbdyT57R2dNp46I17c1KL8atQH97n3yv9d9ZaC87O | ||
6tOohLmue7L3lKxPDpY60VFna5BjJwvrhW4gvsd11Ko4c39FSu8 | ||
ogBSZ6E1EOlmVZDX+cBjuw4dGihcrHqWW5V3k2X/ksAKb+4A74g | ||
AG8pCr/ifPEj9kTWb71IIF5RHkD6JqeGJdKaWFHDpWlYhKNTLRt | ||
3gmcgdLmM5MN9A5khwBzPYiF5oaWT1COxh/Rjdz5V0+jUvyRvc9 | ||
a/rvc6hM6quXSmlAwA0U= | ||
file: | ||
- pega-kubernetes-example.tar.gz | ||
- pega-openshift-example.tar.gz | ||
- pega-azure-aks-example.tar.gz | ||
- pega-aws-eks-example.tar.gz | ||
- pega-google-gke-example.tar.gz | ||
- pega-pivotal-pks-example.tar.gz | ||
skip_cleanup: true | ||
on: | ||
repo: pegasystems/pega-helm-charts | ||
tags: true | ||
- provider: bintray | ||
file: descriptor.json | ||
user: bintrayautomation | ||
key: | ||
secure: M1CPmmjJ1OI2luWFRW9Aqregj3b4rQLSnP4ROurkHkewB+HwoZ+QHAQ4JJD0B+br2AddaGKgN1rdzYpyvg0Cl7ZhWnMb96bE+lVbmDzYnUc+Iwd8/PWXNoaFuB5sn5LPVESe8H/ZLdP0IyMbBknBDgdNgKpD9XqH7/UrrNT9jvZSpGFAcMCwLVFiQ1auusnSLOYVr611JadpNZarx7QgPLBtlit+cfi/vEGy7GyYTtFzSbM86gBnm1kViSVM4w1bE4cFs+14KVNiNiwpSzFzK/gBncqQVTz6yaD3bV48Cla5sz3/sDkh3If7pUhcmMYyy9BPk35176TWTHKcqATv/5GxDvQpgaBMlyl0Dhwhb2d++ZZ6V+kYYj+Uf4m4NaxGV6WNrUnW+IPw9qlBWFHnw17u80HU5GapXXNedUi2CjzrH25A0Y6DHqfZubDBXJh31RfWKz0r58bLSGLYxdl96purfLUCeSrsKkZAWS59EmpXiR/f+zSbNmlpG+ryVBsQIPG+cwdPSVUdGBGVp3QzEjVze6gABSQ/2GaMeRterjzBypi8ab4vbIyxY905deoMAwcQHUcvybpNJfRcaowToK0BnMNhy8pn26KYct3oGLVxQe6rlGbQNZrFePSCyNd/ZfYlkWDcLh/j0OH0gdspHTdDfsy8dgS8QzvgNsNKRHk= | ||
skip_cleanup: true | ||
on: | ||
all_branches: true | ||
tags: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
# How to contribute | ||
|
||
## Getting Started | ||
|
||
* Make sure you have a [GitHub account](https://github.com/signup/free) | ||
* Submit a ticket for your issue, assuming one does not already exist. | ||
* Clearly describe the issue including steps to reproduce when it is a bug. | ||
* Make sure you fill in the earliest version that you know has the issue. | ||
* Fork the repository on GitHub | ||
|
||
## Making Changes | ||
|
||
* Create a topic branch from where you want to base your work. | ||
* This is usually the master branch. | ||
* Only target release branches if you are certain your fix must be on that | ||
branch. | ||
* To quickly create a topic branch based on master; `git checkout -b | ||
fix/master/my_contribution master`. Please avoid working directly on the | ||
`master` branch. | ||
* Make commits of logical units. | ||
* Check for unnecessary whitespace with `git diff --check` before committing. | ||
* Make sure your commit messages are in the proper format: | ||
|
||
`ISSUE-1234: terse and to the point message describing change` | ||
|
||
* Make sure you have added the necessary tests for your changes. | ||
* Run _all_ the tests to assure nothing else was accidentally broken. | ||
* Make sure you've done a squash and rebase before submitting | ||
|
||
## Submitting Changes | ||
|
||
* Push your changes to a topic branch in your fork of the repository. | ||
* Submit a pull request. | ||
* After feedback has been given we expect responses within two weeks. After two | ||
weeks we may close the pull request if it isn't showing any activity. | ||
|
||
# Additional Resources | ||
|
||
* [General GitHub documentation](https://help.github.com/) | ||
* [GitHub pull request documentation](https://help.github.com/send-pull-requests/) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,64 +1,66 @@ | ||
dependencies: | ||
helm repo add incubator https://kubernetes-charts-incubator.storage.googleapis.com/ | ||
helm repo list | ||
helm repo add stable https://kubernetes-charts.storage.googleapis.com | ||
helm repo list | ||
helm dependency update ./charts/pega/ | ||
helm dependency update ./charts/addons/ | ||
|
||
examples: dependencies | ||
examples: | ||
mkdir -p ./build/kubernetes | ||
helm template ./charts/pega/ \ | ||
--output-dir ./build/kubernetes \ | ||
--values ./charts/pega/values.yaml \ | ||
--namespace example \ | ||
--set provider=k8s \ | ||
--set actions.execute=deploy | ||
tar -C ./build/kubernetes/pega/templates -cvzf ./pega-kubernetes-example.tar.gz . | ||
--set global.provider=k8s \ | ||
--set global.actions.execute=deploy | ||
tar -C ./build/kubernetes/pega -cvzf ./pega-kubernetes-example.tar.gz . | ||
|
||
mkdir -p ./build/openshift | ||
helm template ./charts/pega/ \ | ||
--output-dir ./build/openshift \ | ||
--values ./charts/pega/values.yaml \ | ||
--namespace example \ | ||
--set provider=openshift \ | ||
--set actions.execute=deploy | ||
tar -C ./build/openshift/pega/templates -cvzf ./pega-openshift-example.tar.gz . | ||
--set global.provider=openshift \ | ||
--set global.actions.execute=deploy | ||
tar -C ./build/openshift/pega -cvzf ./pega-openshift-example.tar.gz . | ||
|
||
mkdir -p ./build/aws-eks | ||
helm template ./charts/pega/ \ | ||
--output-dir ./build/aws-eks \ | ||
--values ./charts/pega/values.yaml \ | ||
--namespace example \ | ||
--set provider=eks \ | ||
--set actions.execute=deploy | ||
tar -C ./build/aws-eks/pega/templates -cvzf ./pega-aws-eks-example.tar.gz . | ||
--set global.provider=eks \ | ||
--set global.actions.execute=deploy | ||
tar -C ./build/aws-eks/pega -cvzf ./pega-aws-eks-example.tar.gz . | ||
|
||
mkdir -p ./build/azure-aks | ||
helm template ./charts/pega/ \ | ||
--output-dir ./build/azure-aks \ | ||
--values ./charts/pega/values.yaml \ | ||
--namespace example \ | ||
--set provider=aks \ | ||
--set actions.execute=deploy | ||
tar -C ./build/azure-aks/pega/templates -cvzf ./pega-azure-aks-example.tar.gz . | ||
--set global.provider=aks \ | ||
--set global.actions.execute=deploy | ||
tar -C ./build/azure-aks/pega -cvzf ./pega-azure-aks-example.tar.gz . | ||
|
||
mkdir -p ./build/google-gke | ||
helm template ./charts/pega/ \ | ||
--output-dir ./build/google-gke \ | ||
--values ./charts/pega/values.yaml \ | ||
--namespace example \ | ||
--set provider=gke \ | ||
--set actions.execute=deploy | ||
tar -C ./build/google-gke/pega/templates -cvzf ./pega-google-gke-example.tar.gz . | ||
--set global.provider=gke \ | ||
--set global.actions.execute=deploy | ||
tar -C ./build/google-gke/pega -cvzf ./pega-google-gke-example.tar.gz . | ||
|
||
mkdir -p ./build/pivotal-pks | ||
helm template ./charts/pega/ \ | ||
--output-dir ./build/pivotal-pks \ | ||
--values ./charts/pega/values.yaml \ | ||
--namespace example \ | ||
--set provider=pks \ | ||
--set actions.execute=deploy | ||
tar -C ./build/pivotal-pks/pega/templates -cvzf ./pega-pivotal-pks-example.tar.gz . | ||
--set global.provider=pks \ | ||
--set global.actions.execute=deploy | ||
tar -C ./build/pivotal-pks/pega -cvzf ./pega-pivotal-pks-example.tar.gz . | ||
|
||
clean: | ||
rm -rf ./build | ||
rm -rf ./charts/pega/charts/* | ||
rm -rf ./*.tar.gz | ||
rm -rf ./*.tar.gz |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
#!/bin/bash | ||
|
||
# CHART_VERSION is computed from the TAG details of the commit. Every Github release creates tag with the release name. | ||
# Release name (or) Tag name should be in vX.X.X format. Helm CHART_VERSION would be X.X.X | ||
export CHART_VERSION=$(expr ${TRAVIS_TAG:1}) | ||
export PEGA_FILE_NAME=pega-${CHART_VERSION}.tgz | ||
export ADDONS_FILE_NAME=addons-${CHART_VERSION}.tgz | ||
cat descriptor-template.json | jq '.files[0].includePattern=env.PEGA_FILE_NAME' | jq '.files[0].uploadPattern=env.PEGA_FILE_NAME' | jq '.files[1].includePattern=env.ADDONS_FILE_NAME' | jq '.files[1].uploadPattern=env.ADDONS_FILE_NAME' > descriptor.json | ||
curl -o index.yaml https://dl.bintray.com/pegasystems/pega-helm-charts/index.yaml | ||
helm package --version ${CHART_VERSION} ./charts/pega/ | ||
helm package --version ${CHART_VERSION} ./charts/addons/ | ||
helm repo index --merge index.yaml --url https://dl.bintray.com/pegasystems/pega-helm-charts/ . |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
# Patterns to ignore when building packages. | ||
# This supports shell glob matching, relative path matching, and | ||
# negation (prefixed with !). Only one pattern per line. | ||
.DS_Store | ||
# Common VCS dirs | ||
.git/ | ||
.gitignore | ||
.bzr/ | ||
.bzrignore | ||
.hg/ | ||
.hgignore | ||
.svn/ | ||
# Common backup files | ||
*.swp | ||
*.bak | ||
*.tmp | ||
*~ | ||
# Various IDEs | ||
.project | ||
.idea/ | ||
*.tmproj | ||
.vscode/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
apiVersion: v1 | ||
appVersion: "1.0" | ||
description: A Helm chart for Kubernetes | ||
name: addons | ||
version: 1.2.0 |
Oops, something went wrong.