-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[TEP-0115] Git-based Versioning Validation
Prior to this change, the Catlin validation only supports directory-based catalog path validation (i.e. ./<catalog>/<kind>/<name>/<version>/<name>.yaml). The git-based versioning catalog is proposed in TEP-0115: https://github.com/tektoncd/community/blob/main/teps/0115-tekton-catalog-git-based-versioning.md. with a new file path layout (i.e. ./<catalog>/<kind>/<name>/<name>.yaml). This commit introduces a new flag `versioning` to the `catlin validate` command, indicating the versioning type of the catalog to validate. The value can be set to either `directory` or `git`. The default value is `directory`.
- Loading branch information
1 parent
d69104e
commit ee16b75
Showing
5 changed files
with
125 additions
and
12 deletions.
There are no files selected for viewing
24 changes: 24 additions & 0 deletions
24
pkg/cmd/validate/testdata/task/maven-git-versioning/maven-git-versioning.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
apiVersion: tekton.dev/v1beta1 | ||
kind: Task | ||
metadata: | ||
name: maven-git-versioning | ||
labels: | ||
app.kubernetes.io/version: "0.1" | ||
annotations: | ||
tekton.dev/pipelines.minVersion: "0.12.1" | ||
tekton.dev/tags: build-automation | ||
tekton.dev/categories: Build Tools | ||
tekton.dev/displayName: "maven" | ||
spec: | ||
description: >- | ||
This Task can be used to run a Maven build. | ||
params: | ||
- name: GOALS | ||
type: array | ||
steps: | ||
- name: execute-goals | ||
image: gcr.io/cloud-builders/mvn:3.6.8@sha256:57523fc43394d6d9d2414ee8d1c85ed7a13460cbb268c3cd16d28cfb3859e641 | ||
command: | ||
- mvn | ||
args: | ||
- $(params.GOALS) |
28 changes: 28 additions & 0 deletions
28
pkg/cmd/validate/testdata/task/npm-git-versioning/npm-git-versioning.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
apiVersion: tekton.dev/v1beta1 | ||
kind: Task | ||
metadata: | ||
name: npm-git-versioning | ||
labels: | ||
app.kubernetes.io/version: "0.1" | ||
annotations: | ||
tekton.dev/pipelines.minVersion: "0.17.0" | ||
tekton.dev/tags: build-automation | ||
tekton.dev/categories: Build Tools | ||
tekton.dev/displayName: "npm" | ||
spec: | ||
description: >- | ||
This task can be used to run npm goals on a project. | ||
This task can be used to run npm goals on a project | ||
where package.json is present and has some pre-defined | ||
npm scripts. | ||
params: | ||
- name: GOALS | ||
type: array | ||
steps: | ||
- name: execute-goals | ||
image: docker.io/library/node:12-alpine@sha256:12048cdfd75d944df35f3144132d9bdeee78015fbd6df765edad1be46599b110 | ||
command: | ||
- npm | ||
args: | ||
- $(params.GOALS) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters