Skip to content

Commit

Permalink
Add installer script for local dev
Browse files Browse the repository at this point in the history
This PR adds an installer script for local dev only.

It supports the following arguments:

Global command syntax:
        installer COMMAND [OPTIONS]

Accepted commands:
        help|h                                  Prints this help
        install|i                               Installs the dashboard
        uninstall|u                             Uninstalls the dashboard
        build|b                                 Builds the manifests and docker image and outputs manfiests in the console

Accepted options:
        [--debug]                               Prints additional messages in the console
        [--csrf-secure-cookie]                  Enable secure CSRF cookie
        [--openshift]                           Will build manifests for openshift
        [--read-only]                           Will build manifests for a readonly deployment
        [--namespace <namespace>]               Will override install namespace
        [--pipelines-namespace <namespace>]     Override the namespace where Tekton Pipelines is installed (defaults to tekton-pipelines)
        [--triggers-namespace <namespace>]      Override the namespace where Tekton Triggers is installed (defaults to tekton-pipelines)
        [--ingress-url <url>]                   Will create an additional ingress with the specified url
        [--ingress-secret <secret>]             Will add ssl support to the ingress
  • Loading branch information
charles-edouard.breteche authored and tekton-robot committed Jun 17, 2020
1 parent c05b5c5 commit 4b1c838
Show file tree
Hide file tree
Showing 11 changed files with 523 additions and 9 deletions.
29 changes: 29 additions & 0 deletions overlays/installer/base/flags.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
---
- op: add
path: /spec/template/spec/containers/0/args/-
value:
--logout-url=--logout-url
- op: add
path: /spec/template/spec/containers/0/args/-
value:
--pipelines-namespace=--pipelines-namespace
- op: add
path: /spec/template/spec/containers/0/args/-
value:
--triggers-namespace=--triggers-namespace
- op: add
path: /spec/template/spec/containers/0/args/-
value:
--read-only=--read-only
- op: add
path: /spec/template/spec/containers/0/args/-
value:
--csrf-secure-cookie=--csrf-secure-cookie
- op: add
path: /spec/template/spec/containers/0/args/-
value:
--log-level=--log-level
- op: add
path: /spec/template/spec/containers/0/args/-
value:
--log-format=--log-format
28 changes: 28 additions & 0 deletions overlays/installer/base/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
---
resources:
- ../../../base/200-clusterrole-backend.yaml
- ../../../base/200-clusterrole-extensions.yaml
- ../../../base/200-clusterrole-pipelines.yaml
- ../../../base/200-clusterrole-tenant.yaml
- ../../../base/200-clusterrole-triggers.yaml
- ../../../base/201-clusterrolebinding-backend.yaml
- ../../../base/201-clusterrolebinding-extensions.yaml
# - ../../../base/201-clusterrolebinding-pipelines.yaml
- ../../../base/201-clusterrolebinding-tenant.yaml
# - ../../../base/201-clusterrolebinding-triggers.yaml
- ../../../base/202-extension-crd.yaml
- ../../../base/203-serviceaccount.yaml
- ../../../base/300-deployment.yaml
- ../../../base/300-service.yaml
images:
- name: dashboardImage
newName: github.com/tektoncd/dashboard/cmd/dashboard
patchesJson6902:
- target:
group: apps
version: v1
kind: Deployment
name: tekton-dashboard
namespace: tekton-pipelines
path: flags.yaml
namespace: tekton-dashboard
3 changes: 3 additions & 0 deletions overlays/installer/k8s/base/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
---
resources:
- ../../base
3 changes: 3 additions & 0 deletions overlays/installer/k8s/read-only/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
---
resources:
- ../base
16 changes: 16 additions & 0 deletions overlays/installer/k8s/read-write/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
resources:
- ../base
patchesJson6902:
- target:
group: rbac.authorization.k8s.io
version: v1
kind: ClusterRole
name: tekton-dashboard-backend
path: ../../../full-fat/clusterrole-backend-patch.yaml
- target:
group: rbac.authorization.k8s.io
version: v1
kind: ClusterRole
name: tekton-dashboard-tenant
path: ../../../full-fat/clusterrole-tenant-patch.yaml
13 changes: 13 additions & 0 deletions overlays/installer/openshift/base/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
---
resources:
- ../../base
- ../../../openshift-patches/route.yaml
- ../../../openshift-patches/internal-dashboard-service.yaml
patchesJson6902:
- target:
group: apps
version: v1
kind: Deployment
name: tekton-dashboard
namespace: tekton-pipelines
path: ../../../openshift-patches/oauth-proxy-in-deployment.yaml
3 changes: 3 additions & 0 deletions overlays/installer/openshift/read-only/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
---
resources:
- ../base
16 changes: 16 additions & 0 deletions overlays/installer/openshift/read-write/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
resources:
- ../base
patchesJson6902:
- target:
group: rbac.authorization.k8s.io
version: v1
kind: ClusterRole
name: tekton-dashboard-backend
path: ../../../full-fat/clusterrole-backend-patch.yaml
- target:
group: rbac.authorization.k8s.io
version: v1
kind: ClusterRole
name: tekton-dashboard-tenant
path: ../../../full-fat/clusterrole-tenant-patch.yaml
Loading

0 comments on commit 4b1c838

Please sign in to comment.