Skip to content

Commit

Permalink
feat: add chart for controller-compliance
Browse files Browse the repository at this point in the history
  • Loading branch information
pmuir committed Oct 14, 2018
1 parent 8660cff commit d305d29
Show file tree
Hide file tree
Showing 4 changed files with 65 additions and 0 deletions.
8 changes: 8 additions & 0 deletions charts/controller-compliance/Chart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
apiVersion: v1
description: Helm chart to enforce compliance for each team
icon: https://raw.githubusercontent.com/jenkins-x/jenkins-x-platform/master/images/go.png
maintainers:
- name: Jenkins X Team
email: [email protected]
name: compliance-role
version: 0.0.1-SNAPSHOT
22 changes: 22 additions & 0 deletions charts/controller-compliance/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
OS := $(shell uname)

build:
helm init --client-only
helm repo add chartmuseum http://jenkins-x-chartmuseum:8080
helm repo add chartmuseum https://chartmuseum.build.cd.jenkins-x.io
ifeq ($(OS),Darwin)
sed -i "" -e "s/version:.*/version: $(PREVIEW_VERSION)/" Chart.yaml
sed -i "" -e "s/version:.*/version: $(PREVIEW_VERSION)/" ../*/Chart.yaml
sed -i "" -e "s/tag: .*/tag: $(PREVIEW_VERSION)/" values.yaml
else ifeq ($(OS),Linux)
sed -i -e "s/version:.*/version: $(PREVIEW_VERSION)/" Chart.yaml
sed -i -e "s/version:.*/version: $(PREVIEW_VERSION)/" ../*/Chart.yaml
sed -i -e "s/repository: .*/repository: $(JENKINS_X_DOCKER_REGISTRY_SERVICE_HOST):$(JENKINS_X_DOCKER_REGISTRY_SERVICE_PORT)\/jenkins-x-bot\/controller-role/" values.yaml
sed -i -e "s/tag: .*/tag: $(PREVIEW_VERSION)/" values.yaml
else
echo "platform $(OS) not supported to release from"
exit -1
endif
echo " version: $(PREVIEW_VERSION)" >> requirements.yaml
helm dependency build
helm lint
3 changes: 3 additions & 0 deletions charts/controller-compliance/requirements.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
dependencies:
- name: compliance-role
repository: file://../jx
32 changes: 32 additions & 0 deletions charts/controller-compliance/values.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
compliance-role:
serviceaccount:
enabled: true
deployment:
enabled: true
args:
- "compliance"
- "role"
role:
enabled: true
rules:
- apiGroups:
- jenkins.io
resources:
compliancechecks
verbs:
- get
- create
- update
- watch
- apiGroups:
- jenkins.io
resources:
pipelineactivities
verbs:
- get
- apiGroups:
- ""
resources:
- pods
verbs:
- watch

0 comments on commit d305d29

Please sign in to comment.