mirror of https://github.com/knative/func.git
doc: refer specific verision of Tekton not latest (#1669)
* doc: refer specific verision of Tekton not latest Signed-off-by: Matej Vasek <mvasek@redhat.com> * fixup Signed-off-by: Matej Vasek <mvasek@redhat.com> * fixup: shell-check Signed-off-by: Matej Vasek <mvasek@redhat.com> --------- Signed-off-by: Matej Vasek <mvasek@redhat.com>
This commit is contained in:
parent
2502819b61
commit
d7660abb3f
|
@ -8,7 +8,7 @@ This guide describes how you can build a Function on Cluster with Tekton Pipelin
|
||||||
## Prerequisite
|
## Prerequisite
|
||||||
1. Install Tekton Pipelines on the cluster. Please refer to [Tekton Pipelines documentation](https://github.com/tektoncd/pipeline/blob/main/docs/install.md) or run the following command:
|
1. Install Tekton Pipelines on the cluster. Please refer to [Tekton Pipelines documentation](https://github.com/tektoncd/pipeline/blob/main/docs/install.md) or run the following command:
|
||||||
```bash
|
```bash
|
||||||
kubectl apply -f https://storage.googleapis.com/tekton-releases/pipeline/latest/release.yaml
|
kubectl apply -f https://storage.googleapis.com/tekton-releases/pipeline/previous/v0.42.0/release.yaml
|
||||||
```
|
```
|
||||||
|
|
||||||
## Enabling a namespace to run Function related Tekton Pipelines
|
## Enabling a namespace to run Function related Tekton Pipelines
|
||||||
|
|
|
@ -22,29 +22,29 @@ set -o pipefail
|
||||||
|
|
||||||
export TERM="${TERM:-dumb}"
|
export TERM="${TERM:-dumb}"
|
||||||
|
|
||||||
tekton_release="previous/v0.38.3"
|
tekton_release="previous/v0.42.0"
|
||||||
git_clone_release="0.4"
|
git_clone_release="0.4"
|
||||||
namespace="${NAMESPACE:-default}"
|
namespace="${NAMESPACE:-default}"
|
||||||
tasks_source_path=$(dirname $(cd $(dirname $0) && pwd ))
|
tasks_source_path="$(dirname "$(cd "$(dirname "$0")" && pwd )")"
|
||||||
|
|
||||||
tekton() {
|
tekton() {
|
||||||
echo "Installing Tekton..."
|
echo "Installing Tekton..."
|
||||||
kubectl apply -f https://storage.googleapis.com/tekton-releases/pipeline/${tekton_release}/release.yaml
|
kubectl apply -f "https://storage.googleapis.com/tekton-releases/pipeline/${tekton_release}/release.yaml"
|
||||||
sleep 10
|
sleep 10
|
||||||
kubectl wait pod --for=condition=Ready --timeout=180s -n tekton-pipelines -l "app=tekton-pipelines-controller"
|
kubectl wait pod --for=condition=Ready --timeout=180s -n tekton-pipelines -l "app=tekton-pipelines-controller"
|
||||||
kubectl wait pod --for=condition=Ready --timeout=180s -n tekton-pipelines -l "app=tekton-pipelines-webhook"
|
kubectl wait pod --for=condition=Ready --timeout=180s -n tekton-pipelines -l "app=tekton-pipelines-webhook"
|
||||||
sleep 10
|
sleep 10
|
||||||
|
|
||||||
kubectl create clusterrolebinding ${namespace}:knative-serving-namespaced-admin \
|
kubectl create clusterrolebinding "${namespace}:knative-serving-namespaced-admin" \
|
||||||
--clusterrole=knative-serving-namespaced-admin --serviceaccount=${namespace}:default
|
--clusterrole=knative-serving-namespaced-admin --serviceaccount="${namespace}:default"
|
||||||
}
|
}
|
||||||
|
|
||||||
tekton_tasks() {
|
tekton_tasks() {
|
||||||
echo "Creating Pipeline tasks..."
|
echo "Creating Pipeline tasks..."
|
||||||
kubectl apply -f https://raw.githubusercontent.com/tektoncd/catalog/master/task/git-clone/${git_clone_release}/git-clone.yaml
|
kubectl apply -f "https://raw.githubusercontent.com/tektoncd/catalog/master/task/git-clone/${git_clone_release}/git-clone.yaml"
|
||||||
kubectl apply -f ${tasks_source_path}/pkg/pipelines/resources/tekton/task/func-buildpacks/0.1/func-buildpacks.yaml
|
kubectl apply -f "${tasks_source_path}/pkg/pipelines/resources/tekton/task/func-buildpacks/0.1/func-buildpacks.yaml"
|
||||||
kubectl apply -f ${tasks_source_path}/pkg/pipelines/resources/tekton/task/func-s2i/0.1/func-s2i.yaml
|
kubectl apply -f "${tasks_source_path}/pkg/pipelines/resources/tekton/task/func-s2i/0.1/func-s2i.yaml"
|
||||||
kubectl apply -f ${tasks_source_path}/pkg/pipelines/resources/tekton/task/func-deploy/0.1/func-deploy.yaml
|
kubectl apply -f "${tasks_source_path}/pkg/pipelines/resources/tekton/task/func-deploy/0.1/func-deploy.yaml"
|
||||||
}
|
}
|
||||||
|
|
||||||
## Parse input parameters
|
## Parse input parameters
|
||||||
|
@ -56,7 +56,7 @@ if [ $# -gt 1 ] ; then
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
if [ $# -eq 1 ] ; then
|
if [ $# -eq 1 ] ; then
|
||||||
if [ $1 == "--tasks-only" ]
|
if [ "$1" == "--tasks-only" ]
|
||||||
then
|
then
|
||||||
tasks_only=true
|
tasks_only=true
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in New Issue