Skip to content

Commit

Permalink
Remove linting from release pipelines 🧹
Browse files Browse the repository at this point in the history
This might be a controversial choice but I think our release Pipelines
should only include Tasks that we expect to give us useful feedback
about the release.

Linting should never fail on a release Pipeline since any issues should
be caught in the PR and
tektoncd/plumbing#241 is making linting
flakey.

I also made it so build and unit test can run in parallel since neither depends
on the other.

I tested this by manually applying the pipelines and manually triggering
the nightly cron:

```
 k --context dogfood create job --from cronjob/nightly-cron-trigger-pipeline-nightly-release nightly-cron-trigger-pipeline-nightly-release-manual-03232020
```
  • Loading branch information
bobcatfish committed Mar 23, 2020
1 parent 0d9a410 commit 871dc19
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 34 deletions.
1 change: 0 additions & 1 deletion tekton/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,6 @@ Install Task from plumbing too:

```bash
# Apply the Tasks we are using from the catalog
kubectl apply -f https://raw.githubusercontent.com/tektoncd/catalog/master/golang/lint.yaml
kubectl apply -f https://raw.githubusercontent.com/tektoncd/catalog/master/golang/build.yaml
kubectl apply -f https://raw.githubusercontent.com/tektoncd/catalog/master/golang/tests.yaml
kubectl apply -f https://raw.githubusercontent.com/tektoncd/plumbing/master/tekton/resources/release/
Expand Down
16 changes: 0 additions & 16 deletions tekton/release-pipeline-nightly.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,22 +39,7 @@ spec:
- name: notification
type: cloudEvent
tasks:
- name: lint
taskRef:
name: golangci-lint
params:
- name: package
value: $(params.package)
- name: version
value: v1.24
- name: flags
value: "-v --timeout 10m"
resources:
inputs:
- name: source
resource: source-repo
- name: unit-tests
runAfter: [lint]
taskRef:
name: golang-test
params:
Expand All @@ -65,7 +50,6 @@ spec:
- name: source
resource: source-repo
- name: build
runAfter: [lint]
taskRef:
name: golang-build
params:
Expand Down
18 changes: 1 addition & 17 deletions tekton/release-pipeline.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -57,23 +57,7 @@ spec:
resource: bucket
- name: source-to-release
resource: source-repo
- name: lint
runAfter: [precheck]
taskRef:
name: golangci-lint
params:
- name: package
value: $(params.package)
- name: flags
value: -v
- name: version
value: v1.24
resources:
inputs:
- name: source
resource: source-repo
- name: unit-tests
runAfter: [lint]
taskRef:
name: golang-test
params:
Expand All @@ -86,7 +70,7 @@ spec:
- name: source
resource: source-repo
- name: build
runAfter: [lint]
runAfter: [precheck]
taskRef:
name: golang-build
params:
Expand Down

0 comments on commit 871dc19

Please sign in to comment.