Skip to content

Commit

Permalink
[test] Remove tekton installation task (kubeflow#538)
Browse files Browse the repository at this point in the history
the kfp-tekton install manifest already includes
tekton, therefore, remove the tekton deploy/undeploy tasks
also add tasks to build cacheserver and frontend
  • Loading branch information
yhwang authored Apr 13, 2021
1 parent 6adfcc6 commit 24c2e5b
Show file tree
Hide file tree
Showing 5 changed files with 362 additions and 41 deletions.
23 changes: 23 additions & 0 deletions .tekton/listener.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@ spec:
default: iamapikey
- name: docker-password
description: iam api key
- name: dockerhub-username
description: username for docker hub
- name: dockerhub-password
description: dockerhub password/token
- name: tekton-version
description: tekton version
- name: tekton-ns
Expand All @@ -46,6 +50,15 @@ spec:
- name: slack-channel
description: slack channel
default: ""
- name: publish-to-dockerhub
description: publish images to dockerhub
default: "0"
- name: image-tag
description: image tag
default: "nightly"
- name: dockerhub-namespace
description: dockerhub namespace
default: aipipeline
resourcetemplates:
- apiVersion: v1
kind: PersistentVolumeClaim
Expand Down Expand Up @@ -86,6 +99,10 @@ spec:
value: $(params.docker-username)
- name: docker-password
value: $(params.docker-password)
- name: dockerhub-username
value: $(params.dockerhub-username)
- name: dockerhub-password
value: $(params.dockerhub-password)
- name: resource-group
value: $(params.resource-group)
- name: org
Expand All @@ -104,6 +121,12 @@ spec:
value: $(params.slack-webhook)
- name: slack-channel
value: $(params.slack-channel)
- name: image-tag
value: $(params.image-tag)
- name: dockerhub-namespace
value: $(params.dockerhub-namespace)
- name: publish-to-dockerhub
value: $(params.publish-to-dockerhub)
---
apiVersion: tekton.dev/v1beta1
kind: TriggerBinding
Expand Down
108 changes: 108 additions & 0 deletions .tekton/pipeline.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@ spec:
default: iamapikey
- name: docker-password
description: iam api key
- name: dockerhub-username
description: dockerhub username
- name: dockerhub-password
description: dockerhub password/token
- name: resource-group
description: resource group
default: default
Expand All @@ -45,6 +49,15 @@ spec:
- name: slack-channel
description: slack channel
default: ""
- name: publish-to-dockerhub
description: publish images to dockerhub
default: "0"
- name: image-tag
description: image tag
default: "nightly"
- name: dockerhub-namespace
description: dockerhub namespace
default: aipipeline
workspaces:
- name: pipeline-pvc
tasks:
Expand Down Expand Up @@ -214,6 +227,61 @@ spec:
workspaces:
- name: task-pvc
workspace: pipeline-pvc
- name: build-images-cacheserver
retries: 1
taskRef:
name: build-images
runAfter:
- test
params:
- name: apikey
value: $(params.apikey)
- name: image-name
value: cache-server
- name: docker-root
value: .
- name: docker-file
value: backend/Dockerfile.cacheserver
- name: registry-url
value: $(params.registry-url)
- name: registry-namespace
value: $(params.registry-namespace)
- name: docker-username
value: iamapikey
- name: docker-password
value: $(params.docker-password)
- name: run-task
value: image
workspaces:
- name: task-pvc
workspace: pipeline-pvc
- name: build-images-frontend
taskRef:
name: build-images-args
runAfter:
- test
params:
- name: apikey
value: $(params.apikey)
- name: image-name
value: frontend
- name: docker-root
value: .
- name: docker-file
value: frontend/Dockerfile
- name: registry-url
value: $(params.registry-url)
- name: registry-namespace
value: $(params.registry-namespace)
- name: docker-username
value: iamapikey
- name: docker-password
value: $(params.docker-password)
- name: run-task
value: image
workspaces:
- name: task-pvc
workspace: pipeline-pvc
- name: deploy
taskRef:
name: deploy
Expand All @@ -222,6 +290,8 @@ spec:
- build-images-persistenceagent
- build-images-metadata-writer
- build-images-scheduledworkflow
- build-images-cacheserver
- build-images-frontend
params:
- name: apikey
value: $(params.apikey)
Expand Down Expand Up @@ -259,11 +329,49 @@ spec:
workspaces:
- name: task-pvc
workspace: pipeline-pvc
- name: publish-images
taskRef:
name: publish-images
runAfter:
- e2e-test
when:
- input: $(params.publish-to-dockerhub)
operator: in
values:
- '1'
params:
- name: apikey
value: $(params.apikey)
- name: kubernetes-cluster
value: $(params.kubernetes-cluster)
- name: kubeflow-ns
value: $(params.kubeflow-ns)
- name: registry-url
value: $(params.registry-url)
- name: registry-namespace
value: $(params.registry-namespace)
- name: docker-username
value: $(params.docker-username)
- name: docker-password
value: $(params.docker-password)
- name: dockerhub-username
value: $(params.dockerhub-username)
- name: dockerhub-password
value: $(params.dockerhub-password)
- name: image-tag
value: $(params.image-tag)
- name: dockerhub-namespace
value: $(params.dockerhub-namespace)
workspaces:
- name: task-pvc
workspace: pipeline-pvc
finally:
- name: undeploy
taskRef:
name: undeploy
params:
- name: kubernetes-cluster
value: $(params.kubernetes-cluster)
- name: apikey
value: $(params.apikey)
- name: kubeflow-ns
Expand Down
Loading

0 comments on commit 24c2e5b

Please sign in to comment.