1
0
mirror of https://github.com/tektoncd/catalog.git synced 2024-12-04 07:07:52 +00:00
catalog/kn/kn-deployer.yaml
Navid Shaikh 55aaaadc75 Array arguments based kn task
Fixes #79

 Changes:
 1. Renames task `kn-create` to `kn`
 2. `kn` task takes a parameter of type array as `ARGS`
 3. `kn` task defines a resource of type image as `image`
 4. User should reference the `image` as an element of array parameter `ARGS` for e.g. `--image=$(inputs.resources.image.url)`
 5. Additional `ClusterRole` for `kn-deployer` account for `revisions` and `routes` resources
 6. Adds examples in README.md for creating and updating a Knative Service
 7. Adds `kn-image` parameter to task for referencing the kn CLI image to be used, defaults to latest released version of kn image available `gcr.io/knative-releases/github.com/knative/client/cmd/kn`
2019-09-24 08:28:12 -05:00

32 lines
746 B
YAML

# Define a ServiceAccount named kn-deployer-account that has permission to
# manage Knative services.
apiVersion: v1
kind: ServiceAccount
metadata:
name: kn-deployer-account
namespace: default
---
kind: ClusterRole
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: kn-deployer
rules:
- apiGroups: ["serving.knative.dev"]
resources: ["services", "revisions", "routes"]
verbs: ["get", "list", "create", "update", "delete", "patch", "watch"]
---
apiVersion: rbac.authorization.k8s.io/v1beta1
kind: ClusterRoleBinding
metadata:
name: kn-deployer-binding
subjects:
- kind: ServiceAccount
name: kn-deployer-account
namespace: default
roleRef:
kind: ClusterRole
name: kn-deployer
apiGroup: rbac.authorization.k8s.io