From 87954a4388992b8bfd81f53f3b3dcbd39a82c294 Mon Sep 17 00:00:00 2001 From: cmoulliard Date: Fri, 6 Sep 2024 12:29:21 +0200 Subject: [PATCH] Clean duplicate params, finally, etc Signed-off-by: cmoulliard --- .../konflux/build-bash-jam-cfg.yaml | 41 ------------------- .../konflux/build-bash-pack-cfg.yaml | 41 ------------------- .../konflux-default-pipeline.yaml | 10 +++++ 3 files changed, 10 insertions(+), 82 deletions(-) diff --git a/configurations/konflux/build-bash-jam-cfg.yaml b/configurations/konflux/build-bash-jam-cfg.yaml index c68a807..c63e8c8 100644 --- a/configurations/konflux/build-bash-jam-cfg.yaml +++ b/configurations/konflux/build-bash-jam-cfg.yaml @@ -19,33 +19,8 @@ job: resourceType: PipelineRun name: quarkus-1-on-push description: PipelineRun performing a build of a Quarkus application using a bash script - - workspaces: - - name: workspace - volumeClaimTemplate: - storage: 1Gi - accessMode: ReadWriteOnce - - name: git-auth - secret: - name: "{{ git_auth_secret }}" - - results: - - IMAGE_URL: "$(tasks.build-container.results.IMAGE_URL)" - - IMAGE_DIGEST: "$(tasks.build-container.results.IMAGE_DIGEST)" - - BASE_IMAGES_DIGESTS: "$(tasks.build-container.results.BASE_IMAGES_DIGESTS)" - - CHAINS-GIT_URL: "$(tasks.clone-repository.results.url)" - - CHAINS-GIT_COMMIT: "$(tasks.clone-repository.results.commit)" params: - - git-url: "{{source_url}}" - - revision: "{{revision}}" - - output-image: "quay.io/ch007m/user-ns1/my-quarkus/quarkus-1:{{revision}}" - - image-expires-after: "5d" - - build-image-index: "" - # We need the following parameters when defined part of the PipelineSpec with default value and used by a task - - build-source-image: false - - prefetch-input: "" - # Buildpack params - source-dir: "source" - imageUrl: "buildpacksio/pack" @@ -59,22 +34,6 @@ job: - quarkus-hello:1.0 actions: - # Finally - - name: show-sbom - finally: true - ref: bundle://quay.io/konflux-ci/tekton-catalog/task-show-sbom:0.1@sha256:9bfc6b99ef038800fe131d7b45ff3cd4da3a415dd536f7c657b3527b01c4a13b - params: - - IMAGE_URL: "$(tasks.build-container.results.IMAGE_URL)" - - - name: summary # Konflux uses as name show-summary !! - finally: true - ref: bundle://quay.io/konflux-ci/tekton-catalog/task-summary:0.2@sha256:d97c04ab42f277b1103eb6f3a053b247849f4f5b3237ea302a8ecada3b24e15b - params: - - pipelinerun-name: "$(context.pipelineRun.name)" - - git-url: "$(tasks.clone-repository.results.url)?rev=$(tasks.clone-repository.results.commit)" - - image-url: "$(params.output-image)" - - build-task-status: "$(tasks.build-container.status)" - # Tasks - name: jam params: diff --git a/configurations/konflux/build-bash-pack-cfg.yaml b/configurations/konflux/build-bash-pack-cfg.yaml index d52379a..7ef1b47 100644 --- a/configurations/konflux/build-bash-pack-cfg.yaml +++ b/configurations/konflux/build-bash-pack-cfg.yaml @@ -19,32 +19,7 @@ job: name: pack-build-builder-image description: PipelineRun using the pack cli to build the builder image - workspaces: - - name: workspace - volumeClaimTemplate: - storage: 1Gi - accessMode: ReadWriteOnce - - name: git-auth - secret: - name: "{{ git_auth_secret }}" - - results: - - IMAGE_URL: "$(tasks.build-container.results.IMAGE_URL)" - - IMAGE_DIGEST: "$(tasks.build-container.results.IMAGE_DIGEST)" - - BASE_IMAGES_DIGESTS: "$(tasks.build-container.results.BASE_IMAGES_DIGESTS)" - - CHAINS-GIT_URL: "$(tasks.clone-repository.results.url)" - - CHAINS-GIT_COMMIT: "$(tasks.clone-repository.results.commit)" - params: - - git-url: "{{source_url}}" - - revision: "{{revision}}" - - output-image: "quay.io/ch007m/builder-ubi-base:{{revision}}" - - image-expires-after: "5d" - - build-image-index: "" - # We need the following parameters when defined part of the PipelineSpec with default value and used by a task - - build-source-image: false - - prefetch-input: "" - # Buildpack params - source-dir: "source" - imageUrl: "buildpacksio/pack" @@ -57,22 +32,6 @@ job: - $(workspaces.source.path)/$(params.SOURCE_SUBPATH)/builder.toml actions: - # Finally - - name: show-sbom - finally: true - ref: bundle://quay.io/konflux-ci/tekton-catalog/task-show-sbom:0.1@sha256:9bfc6b99ef038800fe131d7b45ff3cd4da3a415dd536f7c657b3527b01c4a13b - params: - - IMAGE_URL: "$(tasks.build-container.results.IMAGE_URL)" - - - name: summary # Konflux uses as name show-summary !! - finally: true - ref: bundle://quay.io/konflux-ci/tekton-catalog/task-summary:0.2@sha256:d97c04ab42f277b1103eb6f3a053b247849f4f5b3237ea302a8ecada3b24e15b - params: - - pipelinerun-name: "$(context.pipelineRun.name)" - - git-url: "$(tasks.clone-repository.results.url)?rev=$(tasks.clone-repository.results.commit)" - - image-url: "$(params.output-image)" - - build-task-status: "$(tasks.build-container.status)" - # Tasks #- name: virtualmachine # params: diff --git a/src/main/resources/dev/snowdrop/configuration/konflux-default-pipeline.yaml b/src/main/resources/dev/snowdrop/configuration/konflux-default-pipeline.yaml index 844f635..6223ddc 100644 --- a/src/main/resources/dev/snowdrop/configuration/konflux-default-pipeline.yaml +++ b/src/main/resources/dev/snowdrop/configuration/konflux-default-pipeline.yaml @@ -35,6 +35,16 @@ job: secret: name: "{{ git_auth_secret }}" + params: + - git-url: "{{source_url}}" + - revision: "{{revision}}" + - output-image: "quay.io/ch007m/builder-ubi-base:{{revision}}" + - image-expires-after: "5d" + - build-image-index: "" + # We need the following parameters when defined part of the PipelineSpec with default value and used by a task + - build-source-image: false + - prefetch-input: "" + results: - IMAGE_URL: "$(tasks.build-container.results.IMAGE_URL)" - IMAGE_DIGEST: "$(tasks.build-container.results.IMAGE_DIGEST)"