Skip to content

Commit

Permalink
Merge pull request tektoncd#188 from chmouel/merge2-upstream-v1beta-t…
Browse files Browse the repository at this point in the history
…o-release-v0.11

New merge from upstream v1beta to release v0.11
  • Loading branch information
openshift-merge-robot authored Apr 10, 2020
2 parents 62e2ad5 + 1a123bb commit 2775542
Show file tree
Hide file tree
Showing 6 changed files with 53 additions and 4 deletions.
5 changes: 4 additions & 1 deletion buildah/buildah.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,17 @@ spec:
- name: TLSVERIFY
description: Verify the TLS on the registry endpoint (for push/pull to a non-TLS registry)
default: "true"
- name: FORMAT
description: The format of the built container, oci or docker
default: "oci"
workspaces:
- name: source

steps:
- name: build
image: $(params.BUILDER_IMAGE)
workingDir: $(workspaces.source.path)
command: ['buildah', 'bud', '--tls-verify=$(params.TLSVERIFY)', '--layers', '-f', '$(params.DOCKERFILE)', '-t', '$(params.IMAGE)', '$(params.CONTEXT)']
command: ['buildah', 'bud', '--format=$(params.FORMAT)', '--tls-verify=$(params.TLSVERIFY)', '--layers', '-f', '$(params.DOCKERFILE)', '-t', '$(params.IMAGE)', '$(params.CONTEXT)']
volumeMounts:
- name: varlibcontainers
mountPath: /var/lib/containers
Expand Down
13 changes: 12 additions & 1 deletion github/add_comment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,24 @@ spec:
description: |
The GitHub host, adjust this if you run a GitHub enteprise.
default: "api.github.com"
type: string

- name: API_PATH_PREFIX
description: |
The API path prefix, GitHub Enterprise has a prefix e.g. /api/v3
default: ""
type: string

- name: REQUEST_URL
description: |
The GitHub issue or pull request URL where we want to add a new
comment.
type: string

- name: COMMENT
description: |
The actual comment to add.
type: string
steps:
- name: add-comment
env:
Expand All @@ -40,7 +51,7 @@ spec:
# This will convert https://github.com/foo/bar/pull/202 to
# api url path /repos/foo/issues/202
api_url = "$(inputs.params.API_PATH_PREFIX)" + "/repos/" + "/".join(split_url[1:3]) + \
api_url = "$(params.API_PATH_PREFIX)" + "/repos/" + "/".join(split_url[1:3]) + \
"/issues/" + split_url[-1]
# Trying to avoid quotes issue as much as possible by using triple
Expand Down
11 changes: 10 additions & 1 deletion github/close_issue.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,19 @@ spec:
description: |
The GitHub host, adjust this if you run a GitHub enteprise.
default: "api.github.com"
type: string

- name: API_PATH_PREFIX
description: |
The API path prefix, GitHub Enterprise has a prefix e.g. /api/v3
default: ""
type: string

- name: REQUEST_URL
description: |
The GitHub issue or pull request URL where we want to add a new
comment.
type: string
steps:
- name: close-issue
env:
Expand All @@ -37,7 +46,7 @@ spec:
# This will convert https://github.com/foo/bar/pull/202 to
# api url path /repos/foo/issues/202
api_url = "$(inputs.params.API_PATH_PREFIX)" + "/repos/" + "/".join(split_url[1:3]) + \
api_url = "$(params.API_PATH_PREFIX)" + "/repos/" + "/".join(split_url[1:3]) + \
"/issues/" + split_url[-1]
# Trying to avoid quotes issue as much as possible by using triple
Expand Down
21 changes: 20 additions & 1 deletion github/set_status.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,29 +12,48 @@ spec:
description: |
The GitHub host, adjust this if you run a GitHub enteprise.
default: "api.github.com"
type: string

- name: API_PATH_PREFIX
description: |
The API path prefix, GitHub Enterprise has a prefix e.g. /api/v3
default: ""
type: string

- name: REPO_FULL_NAME
description: |
The GitHub repository full name, i.e: tektoncd/catalog
type: string

- name: SHA
description: |
Commit SHA to set the status for.
type: string

- name: TARGET_URL
description: |
The target URL to associate with this status. This URL will be linked
from the GitHub UI to allow users to easily see the source of the
status.
type: string

- name: DESCRIPTION
description: |
A short description of the status.
type: string

- name: CONTEXT
description: |
The GitHub context, A string label to differentiate this status from
the status of other systems. ie: "continuous-integration/tekton"
default: "continuous-integration/tekton"
type: string

- name: STATE
description: |
The state of the status. Can be one of the following `error`,
`failure`, `pending`, or `success`.
type: string
steps:
- name: set-status
env:
Expand All @@ -51,7 +70,7 @@ spec:
import os
import http.client
status_url = "/repos/$(params.REPO_FULL_NAME)/" + \
status_url = "$(params.API_PATH_PREFIX)" + "/repos/$(params.REPO_FULL_NAME)/" + \
"statuses/$(params.SHA)"
data = {
Expand Down
6 changes: 6 additions & 0 deletions openshift-client/openshift-client-task.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
apiVersion: tekton.dev/v1beta1
kind: Task
metadata:
Expand All @@ -13,6 +14,11 @@ spec:
type: array
default:
- "help"
resources:
inputs:
- name: source
type: git
optional: true
steps:
- name: oc
image: quay.io/openshift/origin-cli:latest
Expand Down
1 change: 1 addition & 0 deletions test/presubmit-tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
# in a net-negative contributor experience.
export DISABLE_MD_LINTING=1
export DISABLE_MD_LINK_CHECK=1
export DISABLE_YAML_LINTING=1

source $(dirname $0)/../vendor/github.com/tektoncd/plumbing/scripts/presubmit-tests.sh

Expand Down

0 comments on commit 2775542

Please sign in to comment.