From 2d2fcb0cd21b923366664fdd82b7cebc57f76945 Mon Sep 17 00:00:00 2001 From: github-actions Date: Mon, 6 Nov 2023 18:15:19 +0000 Subject: [PATCH] Auto-update experimental tekton resources --- .../tasks/task-buildah/v0.1.0/README.md | 76 ++++++++ .../task-buildah/v0.1.0/task-buildah.yaml | 136 ++++++++++++++ .../tasks/task-s2i-dotnet/v0.1.0/README.md | 83 +++++++++ .../v0.1.0/task-s2i-dotnet.yaml | 168 ++++++++++++++++++ .../tasks/task-s2i-go/v0.1.0/README.md | 83 +++++++++ .../tasks/task-s2i-go/v0.1.0/task-s2i-go.yaml | 168 ++++++++++++++++++ .../tasks/task-s2i-java/v0.1.0/README.md | 83 +++++++++ .../task-s2i-java/v0.1.0/task-s2i-java.yaml | 168 ++++++++++++++++++ .../tasks/task-s2i-nodejs/v0.1.0/README.md | 83 +++++++++ .../v0.1.0/task-s2i-nodejs.yaml | 168 ++++++++++++++++++ .../tasks/task-s2i-perl/v0.1.0/README.md | 83 +++++++++ .../task-s2i-perl/v0.1.0/task-s2i-perl.yaml | 168 ++++++++++++++++++ .../tasks/task-s2i-php/v0.1.0/README.md | 83 +++++++++ .../task-s2i-php/v0.1.0/task-s2i-php.yaml | 168 ++++++++++++++++++ .../tasks/task-s2i-python/v0.1.0/README.md | 83 +++++++++ .../v0.1.0/task-s2i-python.yaml | 168 ++++++++++++++++++ .../tasks/task-s2i-ruby/v0.1.0/README.md | 83 +++++++++ .../task-s2i-ruby/v0.1.0/task-s2i-ruby.yaml | 168 ++++++++++++++++++ .../tasks/task-skopeo-copy/v0.1.0/README.md | 59 ++++++ .../v0.1.0/task-skopeo-copy.yaml | 99 +++++++++++ 20 files changed, 2378 insertions(+) create mode 100644 experimental/tmp/task-containers-0.1.0/release/tasks/task-buildah/v0.1.0/README.md create mode 100644 experimental/tmp/task-containers-0.1.0/release/tasks/task-buildah/v0.1.0/task-buildah.yaml create mode 100644 experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-dotnet/v0.1.0/README.md create mode 100644 experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-dotnet/v0.1.0/task-s2i-dotnet.yaml create mode 100644 experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-go/v0.1.0/README.md create mode 100644 experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-go/v0.1.0/task-s2i-go.yaml create mode 100644 experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-java/v0.1.0/README.md create mode 100644 experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-java/v0.1.0/task-s2i-java.yaml create mode 100644 experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-nodejs/v0.1.0/README.md create mode 100644 experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-nodejs/v0.1.0/task-s2i-nodejs.yaml create mode 100644 experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-perl/v0.1.0/README.md create mode 100644 experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-perl/v0.1.0/task-s2i-perl.yaml create mode 100644 experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-php/v0.1.0/README.md create mode 100644 experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-php/v0.1.0/task-s2i-php.yaml create mode 100644 experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-python/v0.1.0/README.md create mode 100644 experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-python/v0.1.0/task-s2i-python.yaml create mode 100644 experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-ruby/v0.1.0/README.md create mode 100644 experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-ruby/v0.1.0/task-s2i-ruby.yaml create mode 100644 experimental/tmp/task-containers-0.1.0/release/tasks/task-skopeo-copy/v0.1.0/README.md create mode 100644 experimental/tmp/task-containers-0.1.0/release/tasks/task-skopeo-copy/v0.1.0/task-skopeo-copy.yaml diff --git a/experimental/tmp/task-containers-0.1.0/release/tasks/task-buildah/v0.1.0/README.md b/experimental/tmp/task-containers-0.1.0/release/tasks/task-buildah/v0.1.0/README.md new file mode 100644 index 00000000..8c0a41f0 --- /dev/null +++ b/experimental/tmp/task-containers-0.1.0/release/tasks/task-buildah/v0.1.0/README.md @@ -0,0 +1,76 @@ +`Buildah` Tekton Task +----------------------- + +# Abstract + +The `buildah` Task is meant to build [OCI][OCI] container images without the requirement of container runtime daemon like Docker daemon using [Buildah][Buildah], the Task results contain the image name and the SHA256 image digest. + +# Usage + +Please, consider the usage example below: + +```yaml +--- +apiVersion: tekton.dev/v1beta1 +kind: PipelineRun +metadata: {} +spec: + pipelineRef: + name: task-buildah + params: + - name: IMAGE + value: your-image-name + - name: TLS_VERIFY + value: true + - name: VERBOSE + value: false + workspaces: + - name: source + persistentVolumeClaim: + claimName: your-pvc-name +``` +You'll need to replace `your-image-name` with the actual name of the image you want to build, and `your-pvc-name` with the name of the PersistentVolumeClaim where your source code is stored. +In case the Container Registry requires authentication, please consider the [Tekton Pipelines documentation][tektonPipelineAuth]. In a nutshell, you need to create a Kubernetes Secret describing the following attributes: + +```bash +kubectl create secret docker-registry imagestreams \ + --docker-server="image-registry.openshift-image-registry.svc:5000" \ + --docker-username="${REGISTRY_USERNAME}" \ + --docker-password="${REGISTRY_TOKEN}" +``` + +Then make sure the Secret is linked with the Service-Account running the `TaskRun`/`PipelineRun`. + +## Workspace + +| Name | Optional | Description | +| :------------ | :------------------------: | :--------------------------- | +| `source` | `false` | Container build context, like for instnace a application source code followed by a `Containerfile`. | + + +## Params + +| Param | Type | Default | Description | +| :------------ | :------------------------: | :--------------------------- | :------------------------- | +| `IMAGE` | `string` | (required) | Fully qualified source container image name, including tag, to be built by buildah. | +| `CONTAINERFILE_PATH` | `string` | `Containerfile` | Path to the `Containerfile` (or `Dockerfile`) relative to the `source` workspace. | +| `TLS_VERIFY` | `string` | `true` | Sets the TLS verification flags, `true` is recommended. | +| `VERBOSE` | `string` | `false` | Shows a more verbose (debug) output. | +| `SUBDIRECTORY` | `string` | `.` | Relative subdirectory to the `source` Workspace for the build-context. | +| `STORAGE_DRIVER` | `string` | `overlay` | Set buildah storage driver to reflect the currrent cluster node's settings. | +| `BUILD_EXTRA_ARGS` | `string` | `` | Extra parameters passed for the build command when building images. | +| `PUSH_EXTRA_ARGS` | `string` | `` | Extra parameters passed for the push command when pushing images. | +| `SKIP_PUSH` | `string` | `false` | Skip pushing the image to the container registry. | + + +## Results + +| Result | Description | +| :------------ | :------------------------- | +| `IMAGE_URL` | Fully qualified image name. | +| `IMAGE_DIGEST` | SHA256 digest of the image just built. | + +[tektonPipelineAuth]: https://tekton.dev/docs/pipelines/auth/#configuring-docker-authentication-for-docker +[Buildah]: https://github.com/containers/buildah +[OCI]: https://opencontainers.org/ + diff --git a/experimental/tmp/task-containers-0.1.0/release/tasks/task-buildah/v0.1.0/task-buildah.yaml b/experimental/tmp/task-containers-0.1.0/release/tasks/task-buildah/v0.1.0/task-buildah.yaml new file mode 100644 index 00000000..2d1885f3 --- /dev/null +++ b/experimental/tmp/task-containers-0.1.0/release/tasks/task-buildah/v0.1.0/task-buildah.yaml @@ -0,0 +1,136 @@ +--- +# Source: task-containers/templates/task-buildah.yaml +apiVersion: tekton.dev/v1beta1 +kind: Task +metadata: + name: buildah + labels: + app.kubernetes.io/version: 0.1.0 + annotations: + tekton.dev/categories: containers + tekton.dev/pipelines.minVersion: 0.38.0 + tekton.dev/tags: containers +spec: + description: | + Buildah task builds source into a container image and + then pushes it to a container registry. + + workspaces: + - name: source + optional: false + description: | + Container build context, like for instnace a application source code + followed by a `Containerfile`. + + params: + - name: IMAGE + type: string + description: | + Fully qualified container image name to be built by buildah. + - name: CONTAINERFILE_PATH + type: string + default: Containerfile + description: | + Path to the `Containerfile` (or `Dockerfile`) relative to the `source` workspace. + - name: SUBDIRECTORY + type: string + default: "." + description: | + Relative subdirectory to the `source` Workspace for the build-context. + - name: STORAGE_DRIVER + type: string + default: overlay + description: | + Set buildah storage driver to reflect the currrent cluster node's + settings. + - name: BUILD_EXTRA_ARGS + type: string + default: "" + description: | + Extra parameters passed for the build command when building images. + - name: PUSH_EXTRA_ARGS + type: string + default: "" + description: | + Extra parameters passed for the push command when pushing images. + - name: SKIP_PUSH + default: "false" + description: | + Skip pushing the image to the container registry. + - name: TLS_VERIFY + type: string + default: "true" + description: | + Sets the TLS verification flag, `true` is recommended. + - name: VERBOSE + type: string + default: "false" + description: | + Turns on verbose logging, all commands executed will be printed out. + + results: + - name: IMAGE_URL + description: | + Fully qualified image name. + - name: IMAGE_DIGEST + description: | + Digest of the image just built. + + stepTemplate: + env: + + - name: PARAMS_IMAGE + value: "$(params.IMAGE)" + - name: PARAMS_SUBDIRECTORY + value: "$(params.SUBDIRECTORY)" + - name: PARAMS_CONTAINERFILE_PATH + value: "$(params.CONTAINERFILE_PATH)" + - name: PARAMS_STORAGE_DRIVER + value: "$(params.STORAGE_DRIVER)" + - name: PARAMS_BUILD_EXTRA_ARGS + value: "$(params.BUILD_EXTRA_ARGS)" + - name: PARAMS_PUSH_EXTRA_ARGS + value: "$(params.PUSH_EXTRA_ARGS)" + - name: PARAMS_SKIP_PUSH + value: "$(params.SKIP_PUSH)" + - name: PARAMS_TLS_VERIFY + value: "$(params.TLS_VERIFY)" + - name: PARAMS_VERBOSE + value: "$(params.VERBOSE)" + - name: WORKSPACES_SOURCE_BOUND + value: "$(workspaces.source.bound)" + - name: WORKSPACES_SOURCE_PATH + value: "$(workspaces.source.path)" + - name: RESULTS_IMAGE_URL_PATH + value: "$(results.IMAGE_URL.path)" + - name: RESULTS_IMAGE_DIGEST_PATH + value: "$(results.IMAGE_DIGEST.path)" + + steps: + - name: load-scripts + image: docker.io/library/bash:latest + workingDir: /scripts + script: | + set -e + printf '%s' "IyEvdXNyL2Jpbi9lbnYgYmFzaAojCiMgV3JhcHBlciBhcm91bmQgImJ1aWxkYWggYnVkIiB0byBidWlsZCBhbmQgcHVzaCBhIGNvbnRhaW5lciBpbWFnZSBiYXNlZCBvbiBhIENvbnRhaW5lcmZpbGUuCiMKCnNob3B0IC1zI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%s' "IyEvdXNyL2Jpbi9lbnYgYmFzaAoKIyB0ZWt0b24ncyBob21lIGRpcmVjdG9yeQpkZWNsYXJlIC1yeCBURUtUT05fSE9NRT0iJHtURUtUT05fSE9NRTotL3Rla3Rvbi9ob21lfSIKCiMKIyBGdW5jdGlvbnMKIwoKZnVuY3Rpb24gZmFpbCgpIHsKICAgIGVjaG8gIkVSUk9SOiAkeyp9IiAyPiYxCiAgICBleGl0IDEKfQoKZnVuY3Rpb24gcGhhc2UoKSB7CiAgICBlY2hvICItLS0+IFBoYXNlOiAkeyp9Li4uIgp9CgojIGFzc2VydCBsb2NhbCB2YXJpYWJsZXMgYXJlIGV4cG9yZXRlZCBvbiB0aGUgZW52aXJvbm1lbnQKZnVuY3Rpb24gZXhwb3J0ZWRfb3JfZmFpbCgpIHsKICAgIGRlY2xhcmUgLWEgX3JlcXVpcmVkX3ZhcnM9IiR7QH0iCgogICAgZm9yIHYgaW4gJHtfcmVxdWlyZWRfdmFyc1tAXX07IGRvCiAgICAgICAgW1sgLXogIiR7IXZ9IiBdXSAmJgogICAgICAgICAgICBmYWlsICInJHt2fScgZW52aXJvbm1lbnQgdmFyaWFibGUgaXMgbm90IHNldCEiCiAgICBkb25lCgogICAgcmV0dXJuIDAKfQo=" |base64 -d >common.sh + chmod +x buildah-*.sh + volumeMounts: + - name: scripts-dir + mountPath: /scripts + + - name: build + image: registry.access.redhat.com/ubi8/buildah:latest + workingDir: /workspace/source + command: + - /scripts/buildah-bud.sh + securityContext: + privileged: true + volumeMounts: + - name: scripts-dir + mountPath: /scripts + + volumes: + - name: scripts-dir + emptyDir: {} diff --git a/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-dotnet/v0.1.0/README.md b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-dotnet/v0.1.0/README.md new file mode 100644 index 00000000..b86765b3 --- /dev/null +++ b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-dotnet/v0.1.0/README.md @@ -0,0 +1,83 @@ +Source-to-Image Tekton Tasks (`s2i`) +------------------------------------ + +# Abstract + +Describes the Tekton Tasks supporting Source-to-Image for various ecosystems. + +# `s2i` Builder Images + +This section we explain each language ecosystem comes with a predefined set of builder images, supported by Red Hat. + +The `s2i` Task helps in building reproducible container images from source code i.e. task for supporting s2i functionality. + +The s2i Task has been customized with builder images specific to various languages and have been named appropriately as follows: + +| Task Name | Builder Image Used | +| ---------- | ---------------------------------------------------------------------- | +| s2i-python | http://registry.access.redhat.com/ubi8/python-39:latest | +| s2i-go | http://registry.access.redhat.com/ubi8/go-toolset:1.19.10-3 | +| s2i-java | http://registry.access.redhat.com/ubi8/openjdk-11:latest | +| s2i-dotnet | http://registry.access.redhat.com/ubi8/dotnet-60:6.0-37.20230802191230 | +| s2i-php | http://registry.access.redhat.com/ubi9/php-81:1-29 | +| s2i-nodejs | http://registry.access.redhat.com/ubi8/nodejs-18:latest | +| s2i-perl | http://registry.access.redhat.com/ubi9/perl-532:1-91 | +| s2i-ruby | http://registry.access.redhat.com/ubi9/ruby-31:1-50 | + +In case, the above builder images associated with the languages aren’t satisfactory for your source code, you can change it using appropriate parameter. + +# Usage + +Please, consider the usage example below: + +```yaml +--- +apiVersion: tekton.dev/v1beta1 +kind: TaskRun +metadata: {} +spec: + taskRef: + name: s2i-python + params: + - name: IMAGE + value: registry.registry.svc.cluster.local:32222/task-containers/task-s2i-python:latest +``` + +In case the Container Registry requires authentication, please consider the [Tekton Pipelines documentation][tektonPipelineAuth]. In a nutshell, you need to create a Kubernetes Secret describing the following attributes: + +```bash +kubectl create secret docker-registry imagestreams \ + --docker-server="image-registry.openshift-image-registry.svc:5000" \ + --docker-username="${REGISTRY_USERNAME}" \ + --docker-password="${REGISTRY_TOKEN}" +``` + +Then make sure the Secret is linked with the Service-Account running the `TaskRun`/`PipelineRun`. + +## Workspaces + +All of the s2i tasks use the `source` workspace which is meant to contain the Application source code, which acts as the build context for S2I workflow. + + +## Params + +| Param | Type | Default | Description | +| ----------------- | ------ | ------------------------ | ------------------------------------------------------------------------- | +| IMAGE | string | (required) | Fully qualified container image name to be built by s2i | +| IMAGE_SCRIPTS_URL | string | image:///usr/libexec/s2i | URL containing the default assemble and run scripts for the builder image | +| ENV_VARS | array | [] | Array containing string of Environment Variables as "KEY=VALUE” | +| SUBDIRECTORY | string | . | Relative subdirectory to the source Workspace for the build-context. | +| STORAGE_DRIVER | string | overlay | Set buildah storage driver to reflect the currrent cluster node's | +| settings. | +| BUILD_EXTRA_ARGS | string | | Extra parameters passed for the build command when building images. | +| PUSH_EXTRA_ARGS | string | | Extra parameters passed for the push command when pushing images. | +| SKIP_PUSH | string | false | Skip pushing the image to the container registry. | +| TLS_VERIFY | string | true | Sets the TLS verification flag, true is recommended. | +| VERBOSE | string | false | Turns on verbose logging, all commands executed will be printed out. | + +## Results + +| Result | Description | +| ------------ | ------------------------------- | +| IMAGE_URL | Fully qualified image name. | +| IMAGE_DIGEST | Digest of the image just built. | diff --git a/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-dotnet/v0.1.0/task-s2i-dotnet.yaml b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-dotnet/v0.1.0/task-s2i-dotnet.yaml new file mode 100644 index 00000000..dc23b7e5 --- /dev/null +++ b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-dotnet/v0.1.0/task-s2i-dotnet.yaml @@ -0,0 +1,168 @@ +--- +# Source: task-containers/templates/task-s2i-dotnet.yaml +apiVersion: tekton.dev/v1beta1 +kind: Task +metadata: + name: s2i-dotnet + labels: + app.kubernetes.io/version: 0.1.0 + annotations: + tekton.dev/categories: containers + tekton.dev/pipelines.minVersion: 0.38.0 + tekton.dev/tags: containers +spec: + description: | + Builds the source code using the s2i's dotnet builder-image + "registry.access.redhat.com/ubi8/dotnet-60:6.0-37.20230802191230". + + + workspaces: + - name: source + optional: false + description: | + Application source code, the build context for S2I workflow. + + params: + - name: IMAGE + type: string + description: | + Fully qualified container image name to be built by s2i. + - name: IMAGE_SCRIPTS_URL + type: string + default: image:///usr/libexec/s2i + description: | + Specify a URL containing the default assemble and run scripts for the builder image + - name: ENV_VARS + type: array + default: [] + description: | + Array containing string of Environment Variables as "KEY=VALUE" + - name: SUBDIRECTORY + type: string + default: "." + description: | + Relative subdirectory to the `source` Workspace for the build-context. + - name: STORAGE_DRIVER + type: string + default: overlay + description: | + Set buildah storage driver to reflect the currrent cluster node's + settings. + - name: BUILD_EXTRA_ARGS + type: string + default: "" + description: | + Extra parameters passed for the build command when building images. + - name: PUSH_EXTRA_ARGS + type: string + default: "" + description: | + Extra parameters passed for the push command when pushing images. + - name: SKIP_PUSH + default: "false" + description: | + Skip pushing the image to the container registry. + - name: TLS_VERIFY + type: string + default: "true" + description: | + Sets the TLS verification flag, `true` is recommended. + - name: VERBOSE + type: string + default: "false" + description: | + Turns on verbose logging, all commands executed will be printed out. + + results: + - name: IMAGE_URL + description: | + Fully qualified image name. + - name: IMAGE_DIGEST + description: | + Digest of the image just built. + + stepTemplate: + env: + + - name: PARAMS_IMAGE + value: "$(params.IMAGE)" + - name: PARAMS_IMAGE_SCRIPTS_URL + value: "$(params.IMAGE_SCRIPTS_URL)" + - name: PARAMS_SUBDIRECTORY + value: "$(params.SUBDIRECTORY)" + - name: PARAMS_STORAGE_DRIVER + value: "$(params.STORAGE_DRIVER)" + - name: PARAMS_BUILD_EXTRA_ARGS + value: "$(params.BUILD_EXTRA_ARGS)" + - name: PARAMS_PUSH_EXTRA_ARGS + value: "$(params.PUSH_EXTRA_ARGS)" + - name: PARAMS_SKIP_PUSH + value: "$(params.SKIP_PUSH)" + - name: PARAMS_TLS_VERIFY + value: "$(params.TLS_VERIFY)" + - name: PARAMS_VERBOSE + value: "$(params.VERBOSE)" + - name: WORKSPACES_SOURCE_BOUND + value: "$(workspaces.source.bound)" + - name: WORKSPACES_SOURCE_PATH + value: "$(workspaces.source.path)" + - name: RESULTS_IMAGE_URL_PATH + value: "$(results.IMAGE_URL.path)" + - name: RESULTS_IMAGE_DIGEST_PATH + value: "$(results.IMAGE_DIGEST.path)" + + steps: + - name: load-scripts + image: docker.io/library/bash:latest + workingDir: /scripts + script: | + set -e + printf '%s' "IyEvdXNyL2Jpbi9lbnYgYmFzaAojCiMgV3JhcHBlciBhcm91bmQgImJ1aWxkYWggYnVkIiB0byBidWlsZCBhbmQgcHVzaCBhIGNvbnRhaW5lciBpbWFnZSBiYXNlZCBvbiBhIENvbnRhaW5lcmZpbGUuCiMKCnNob3B0IC1zIGluaGVyaXRfZXJyZXhpdApzZXQgLWV1IC1vIHBpcGVmYWlsCgpzb3VyY2UgIiQoZGlybmFtZSAke0JBU0hfU09VUkNFWzBdfSkvY29tbW9uLnNoIgpzb3VyY2UgIiQoZGlybmFtZSAke0JBU0hfU09VUkNFWzBdfSkvYnVpbGRhaC1jb21tb24uc2giCgpmdW5jdGlvbiBfYnVpbGRhaCgpIHsKICAgIGJ1aWxkYWggXAogICAgICAgIC0tc3RvcmFnZS1kcml2ZXI9IiR7UEFSQU1TX1NUT1JBR0VfRFJJVkVSfSIgXAogICAgICAgIC0tdGxzLXZlcmlmeT0iJHtQQVJBTVNfVExTX1ZFUklGWX0iIFwKICAgICAgICAkeyp9Cn0KCiMKIyBQcmVwYXJlCiMKCiMgbWFraW5nIHN1cmUgdGhlIHJlcXVpcmVkIHdvcmtzcGFjZSAic291cmNlIiBpcyBib3VuZGVkLCB3aGljaCBtZWFucyBpdHMgdm9sdW1lIGlzIGN1cnJlbnRseSBtb3VudGVkCiMgYW5kIHJlYWR5IHRvIHVzZQpwaGFzZSAiSW5zcGVjdGluZyBzb3VyY2Ugd29ya3NwYWNlICcke1dPUktTUEFDRVNfU09VUkNFX1BBVEh9JyAoUFdEPScke1BXRH0nKSIKW1sgIiR7V09SS1NQQUNFU19TT1VSQ0VfQk9VTkR9IiAhPSAidHJ1ZSIgXV0gJiYKICAgIGZhaWwgIldvcmtzcGFjZSAnc291cmNlJyBpcyBub3QgYm91bmRlZCIKCnBoYXNlICJBc3NlcnRpbmc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gLS1lbnZpcm9ubWVudC1maWxlICIke1MySV9FTlZJUk9OTUVOVF9GSUxFfSIKCnBoYXNlICJJbnNwZWN0aW5nIHRoZSBDb250YWluZXJmaWxlIGdlbmVyYXRlZCBhdCAnJHtTMklfQ09OVEFJTkVSRklMRV9QQVRIfSciCltbICEgLWYgIiR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH0iIF1dICYmCiAgICBmYWlsICJHZW5lcmF0ZWQgQ29udGFpbmVyZmlsZSBpcyBub3QgZm91bmQhIgoKc2V0ICt4CnBoYXNlICJHZW5lcmF0ZWQgQ29udGFpbmVyZmlsZSBwYXlsb2FkIgplY2hvIC1lbiAiPj4+ICR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH1cbiQoY2F0ICR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH0pXG48PDwgRU9GXG4iCg==" |base64 -d >s2i-generate.sh + chmod +x s2i-*.sh + volumeMounts: + - name: scripts-dir + mountPath: /scripts + + - name: s2i-generate + image: quay.io/openshift-pipeline/s2i:nightly + workingDir: $(workspaces.source.path) + env: + - name: S2I_BUILDER_IMAGE + value: registry.access.redhat.com/ubi8/dotnet-60:6.0-37.20230802191230 + command: + - /scripts/s2i-generate.sh + args: + - "$(params.ENV_VARS[*])" + securityContext: + runAsUser: 0 + volumeMounts: + - name: scripts-dir + mountPath: /scripts + - name: s2i-generate-dir + mountPath: /s2i-generate + + - name: s2i-build + image: registry.access.redhat.com/ubi8/buildah:latest + workingDir: /s2i-generate + command: + - /scripts/s2i-build.sh + securityContext: + privileged: true + volumeMounts: + - name: scripts-dir + mountPath: /scripts + - name: s2i-generate-dir + mountPath: /s2i-generate + + volumes: + - name: scripts-dir + emptyDir: {} + - name: s2i-generate-dir + emptyDir: {} diff --git a/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-go/v0.1.0/README.md b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-go/v0.1.0/README.md new file mode 100644 index 00000000..b86765b3 --- /dev/null +++ b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-go/v0.1.0/README.md @@ -0,0 +1,83 @@ +Source-to-Image Tekton Tasks (`s2i`) +------------------------------------ + +# Abstract + +Describes the Tekton Tasks supporting Source-to-Image for various ecosystems. + +# `s2i` Builder Images + +This section we explain each language ecosystem comes with a predefined set of builder images, supported by Red Hat. + +The `s2i` Task helps in building reproducible container images from source code i.e. task for supporting s2i functionality. + +The s2i Task has been customized with builder images specific to various languages and have been named appropriately as follows: + +| Task Name | Builder Image Used | +| ---------- | ---------------------------------------------------------------------- | +| s2i-python | http://registry.access.redhat.com/ubi8/python-39:latest | +| s2i-go | http://registry.access.redhat.com/ubi8/go-toolset:1.19.10-3 | +| s2i-java | http://registry.access.redhat.com/ubi8/openjdk-11:latest | +| s2i-dotnet | http://registry.access.redhat.com/ubi8/dotnet-60:6.0-37.20230802191230 | +| s2i-php | http://registry.access.redhat.com/ubi9/php-81:1-29 | +| s2i-nodejs | http://registry.access.redhat.com/ubi8/nodejs-18:latest | +| s2i-perl | http://registry.access.redhat.com/ubi9/perl-532:1-91 | +| s2i-ruby | http://registry.access.redhat.com/ubi9/ruby-31:1-50 | + +In case, the above builder images associated with the languages aren’t satisfactory for your source code, you can change it using appropriate parameter. + +# Usage + +Please, consider the usage example below: + +```yaml +--- +apiVersion: tekton.dev/v1beta1 +kind: TaskRun +metadata: {} +spec: + taskRef: + name: s2i-python + params: + - name: IMAGE + value: registry.registry.svc.cluster.local:32222/task-containers/task-s2i-python:latest +``` + +In case the Container Registry requires authentication, please consider the [Tekton Pipelines documentation][tektonPipelineAuth]. In a nutshell, you need to create a Kubernetes Secret describing the following attributes: + +```bash +kubectl create secret docker-registry imagestreams \ + --docker-server="image-registry.openshift-image-registry.svc:5000" \ + --docker-username="${REGISTRY_USERNAME}" \ + --docker-password="${REGISTRY_TOKEN}" +``` + +Then make sure the Secret is linked with the Service-Account running the `TaskRun`/`PipelineRun`. + +## Workspaces + +All of the s2i tasks use the `source` workspace which is meant to contain the Application source code, which acts as the build context for S2I workflow. + + +## Params + +| Param | Type | Default | Description | +| ----------------- | ------ | ------------------------ | ------------------------------------------------------------------------- | +| IMAGE | string | (required) | Fully qualified container image name to be built by s2i | +| IMAGE_SCRIPTS_URL | string | image:///usr/libexec/s2i | URL containing the default assemble and run scripts for the builder image | +| ENV_VARS | array | [] | Array containing string of Environment Variables as "KEY=VALUE” | +| SUBDIRECTORY | string | . | Relative subdirectory to the source Workspace for the build-context. | +| STORAGE_DRIVER | string | overlay | Set buildah storage driver to reflect the currrent cluster node's | +| settings. | +| BUILD_EXTRA_ARGS | string | | Extra parameters passed for the build command when building images. | +| PUSH_EXTRA_ARGS | string | | Extra parameters passed for the push command when pushing images. | +| SKIP_PUSH | string | false | Skip pushing the image to the container registry. | +| TLS_VERIFY | string | true | Sets the TLS verification flag, true is recommended. | +| VERBOSE | string | false | Turns on verbose logging, all commands executed will be printed out. | + +## Results + +| Result | Description | +| ------------ | ------------------------------- | +| IMAGE_URL | Fully qualified image name. | +| IMAGE_DIGEST | Digest of the image just built. | diff --git a/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-go/v0.1.0/task-s2i-go.yaml b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-go/v0.1.0/task-s2i-go.yaml new file mode 100644 index 00000000..79cd53c9 --- /dev/null +++ b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-go/v0.1.0/task-s2i-go.yaml @@ -0,0 +1,168 @@ +--- +# Source: task-containers/templates/task-s2i-go.yaml +apiVersion: tekton.dev/v1beta1 +kind: Task +metadata: + name: s2i-go + labels: + app.kubernetes.io/version: 0.1.0 + annotations: + tekton.dev/categories: containers + tekton.dev/pipelines.minVersion: 0.38.0 + tekton.dev/tags: containers +spec: + description: | + Builds the source code using the s2i's Golang builder-image + "registry.access.redhat.com/ubi8/go-toolset:1.19.10-3". + + + workspaces: + - name: source + optional: false + description: | + Application source code, the build context for S2I workflow. + + params: + - name: IMAGE + type: string + description: | + Fully qualified container image name to be built by s2i. + - name: IMAGE_SCRIPTS_URL + type: string + default: image:///usr/libexec/s2i + description: | + Specify a URL containing the default assemble and run scripts for the builder image + - name: ENV_VARS + type: array + default: [] + description: | + Array containing string of Environment Variables as "KEY=VALUE" + - name: SUBDIRECTORY + type: string + default: "." + description: | + Relative subdirectory to the `source` Workspace for the build-context. + - name: STORAGE_DRIVER + type: string + default: overlay + description: | + Set buildah storage driver to reflect the currrent cluster node's + settings. + - name: BUILD_EXTRA_ARGS + type: string + default: "" + description: | + Extra parameters passed for the build command when building images. + - name: PUSH_EXTRA_ARGS + type: string + default: "" + description: | + Extra parameters passed for the push command when pushing images. + - name: SKIP_PUSH + default: "false" + description: | + Skip pushing the image to the container registry. + - name: TLS_VERIFY + type: string + default: "true" + description: | + Sets the TLS verification flag, `true` is recommended. + - name: VERBOSE + type: string + default: "false" + description: | + Turns on verbose logging, all commands executed will be printed out. + + results: + - name: IMAGE_URL + description: | + Fully qualified image name. + - name: IMAGE_DIGEST + description: | + Digest of the image just built. + + stepTemplate: + env: + + - name: PARAMS_IMAGE + value: "$(params.IMAGE)" + - name: PARAMS_IMAGE_SCRIPTS_URL + value: "$(params.IMAGE_SCRIPTS_URL)" + - name: PARAMS_SUBDIRECTORY + value: "$(params.SUBDIRECTORY)" + - name: PARAMS_STORAGE_DRIVER + value: "$(params.STORAGE_DRIVER)" + - name: PARAMS_BUILD_EXTRA_ARGS + value: "$(params.BUILD_EXTRA_ARGS)" + - name: PARAMS_PUSH_EXTRA_ARGS + value: "$(params.PUSH_EXTRA_ARGS)" + - name: PARAMS_SKIP_PUSH + value: "$(params.SKIP_PUSH)" + - name: PARAMS_TLS_VERIFY + value: "$(params.TLS_VERIFY)" + - name: PARAMS_VERBOSE + value: "$(params.VERBOSE)" + - name: WORKSPACES_SOURCE_BOUND + value: "$(workspaces.source.bound)" + - name: WORKSPACES_SOURCE_PATH + value: "$(workspaces.source.path)" + - name: RESULTS_IMAGE_URL_PATH + value: "$(results.IMAGE_URL.path)" + - name: RESULTS_IMAGE_DIGEST_PATH + value: "$(results.IMAGE_DIGEST.path)" + + steps: + - name: load-scripts + image: docker.io/library/bash:latest + workingDir: /scripts + script: | + set -e + printf '%s' "IyEvdXNyL2Jpbi9lbnYgYmFzaAojCiMgV3JhcHBlciBhcm91bmQgImJ1aWxkYWggYnVkIiB0byBidWlsZCBhbmQgcHVzaCBhIGNvbnRhaW5lciBpbWFnZSBiYXNlZCBvbiBhIENvbnRhaW5lcmZpbGUuCiMKCnNob3B0IC1zIGluaGVyaXRfZXJyZXhpdApzZXQgLWV1IC1vIHBpcGVmYWlsCgpzb3VyY2UgIiQoZGlybmFtZSAke0JBU0hfU09VUkNFWzBdfSkvY29tbW9uLnNoIgpzb3VyY2UgIiQoZGlybmFtZSAke0JBU0hfU09VUkNFWzBdfSkvYnVpbGRhaC1jb21tb24uc2giCgpmdW5jdGlvbiBfYnVpbGRhaCgpIHsKICAgIGJ1aWxkYWggXAogICAgICAgIC0tc3RvcmFnZS1kcml2ZXI9IiR7UEFSQU1TX1NUT1JBR0VfRFJJVkVSfSIgXAogICAgICAgIC0tdGxzLXZlcmlmeT0iJHtQQVJBTVNfVExTX1ZFUklGWX0iIFwKICAgICAgICAkeyp9Cn0KCiMKIyBQcmVwYXJlCiMKCiMgbWFraW5nIHN1cmUgdGhlIHJlcXVpcmVkIHdvcmtzcGFjZSAic291cmNlIiBpcyBib3VuZGVkLCB3aGljaCBtZWFucyBpdHMgdm9sdW1lIGlzIGN1cnJlbnRseSBtb3VudGVkCiMgYW5kIHJlYWR5IHRvIHVzZQpwaGFzZSAiSW5zcGVjdGluZyBzb3VyY2Ugd29ya3NwYWNlICcke1dPUktTUEFDRVNfU09VUkNFX1BBVEh9JyAoUFdEPScke1BXRH0nKSIKW1sgIiR7V09SS1NQQUNFU19TT1VSQ0VfQk9VTkR9IiAhPSAidHJ1ZSIgXV0gJiYKICAgIGZhaWwgIldvcmtzcGFjZSAnc291cmNlJyBpcyBub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DT05UQUlORVJGSUxFX1BBVEh9IiBcCiAgICAgICAgLS1lbnZpcm9ubWVudC1maWxlICIke1MySV9FTlZJUk9OTUVOVF9GSUxFfSIKCnBoYXNlICJJbnNwZWN0aW5nIHRoZSBDb250YWluZXJmaWxlIGdlbmVyYXRlZCBhdCAnJHtTMklfQ09OVEFJTkVSRklMRV9QQVRIfSciCltbICEgLWYgIiR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH0iIF1dICYmCiAgICBmYWlsICJHZW5lcmF0ZWQgQ29udGFpbmVyZmlsZSBpcyBub3QgZm91bmQhIgoKc2V0ICt4CnBoYXNlICJHZW5lcmF0ZWQgQ29udGFpbmVyZmlsZSBwYXlsb2FkIgplY2hvIC1lbiAiPj4+ICR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH1cbiQoY2F0ICR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH0pXG48PDwgRU9GXG4iCg==" |base64 -d >s2i-generate.sh + chmod +x s2i-*.sh + volumeMounts: + - name: scripts-dir + mountPath: /scripts + + - name: s2i-generate + image: quay.io/openshift-pipeline/s2i:nightly + workingDir: $(workspaces.source.path) + env: + - name: S2I_BUILDER_IMAGE + value: registry.access.redhat.com/ubi8/go-toolset:1.19.10-3 + command: + - /scripts/s2i-generate.sh + args: + - "$(params.ENV_VARS[*])" + securityContext: + runAsUser: 0 + volumeMounts: + - name: scripts-dir + mountPath: /scripts + - name: s2i-generate-dir + mountPath: /s2i-generate + + - name: s2i-build + image: registry.access.redhat.com/ubi8/buildah:latest + workingDir: /s2i-generate + command: + - /scripts/s2i-build.sh + securityContext: + privileged: true + volumeMounts: + - name: scripts-dir + mountPath: /scripts + - name: s2i-generate-dir + mountPath: /s2i-generate + + volumes: + - name: scripts-dir + emptyDir: {} + - name: s2i-generate-dir + emptyDir: {} diff --git a/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-java/v0.1.0/README.md b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-java/v0.1.0/README.md new file mode 100644 index 00000000..b86765b3 --- /dev/null +++ b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-java/v0.1.0/README.md @@ -0,0 +1,83 @@ +Source-to-Image Tekton Tasks (`s2i`) +------------------------------------ + +# Abstract + +Describes the Tekton Tasks supporting Source-to-Image for various ecosystems. + +# `s2i` Builder Images + +This section we explain each language ecosystem comes with a predefined set of builder images, supported by Red Hat. + +The `s2i` Task helps in building reproducible container images from source code i.e. task for supporting s2i functionality. + +The s2i Task has been customized with builder images specific to various languages and have been named appropriately as follows: + +| Task Name | Builder Image Used | +| ---------- | ---------------------------------------------------------------------- | +| s2i-python | http://registry.access.redhat.com/ubi8/python-39:latest | +| s2i-go | http://registry.access.redhat.com/ubi8/go-toolset:1.19.10-3 | +| s2i-java | http://registry.access.redhat.com/ubi8/openjdk-11:latest | +| s2i-dotnet | http://registry.access.redhat.com/ubi8/dotnet-60:6.0-37.20230802191230 | +| s2i-php | http://registry.access.redhat.com/ubi9/php-81:1-29 | +| s2i-nodejs | http://registry.access.redhat.com/ubi8/nodejs-18:latest | +| s2i-perl | http://registry.access.redhat.com/ubi9/perl-532:1-91 | +| s2i-ruby | http://registry.access.redhat.com/ubi9/ruby-31:1-50 | + +In case, the above builder images associated with the languages aren’t satisfactory for your source code, you can change it using appropriate parameter. + +# Usage + +Please, consider the usage example below: + +```yaml +--- +apiVersion: tekton.dev/v1beta1 +kind: TaskRun +metadata: {} +spec: + taskRef: + name: s2i-python + params: + - name: IMAGE + value: registry.registry.svc.cluster.local:32222/task-containers/task-s2i-python:latest +``` + +In case the Container Registry requires authentication, please consider the [Tekton Pipelines documentation][tektonPipelineAuth]. In a nutshell, you need to create a Kubernetes Secret describing the following attributes: + +```bash +kubectl create secret docker-registry imagestreams \ + --docker-server="image-registry.openshift-image-registry.svc:5000" \ + --docker-username="${REGISTRY_USERNAME}" \ + --docker-password="${REGISTRY_TOKEN}" +``` + +Then make sure the Secret is linked with the Service-Account running the `TaskRun`/`PipelineRun`. + +## Workspaces + +All of the s2i tasks use the `source` workspace which is meant to contain the Application source code, which acts as the build context for S2I workflow. + + +## Params + +| Param | Type | Default | Description | +| ----------------- | ------ | ------------------------ | ------------------------------------------------------------------------- | +| IMAGE | string | (required) | Fully qualified container image name to be built by s2i | +| IMAGE_SCRIPTS_URL | string | image:///usr/libexec/s2i | URL containing the default assemble and run scripts for the builder image | +| ENV_VARS | array | [] | Array containing string of Environment Variables as "KEY=VALUE” | +| SUBDIRECTORY | string | . | Relative subdirectory to the source Workspace for the build-context. | +| STORAGE_DRIVER | string | overlay | Set buildah storage driver to reflect the currrent cluster node's | +| settings. | +| BUILD_EXTRA_ARGS | string | | Extra parameters passed for the build command when building images. | +| PUSH_EXTRA_ARGS | string | | Extra parameters passed for the push command when pushing images. | +| SKIP_PUSH | string | false | Skip pushing the image to the container registry. | +| TLS_VERIFY | string | true | Sets the TLS verification flag, true is recommended. | +| VERBOSE | string | false | Turns on verbose logging, all commands executed will be printed out. | + +## Results + +| Result | Description | +| ------------ | ------------------------------- | +| IMAGE_URL | Fully qualified image name. | +| IMAGE_DIGEST | Digest of the image just built. | diff --git a/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-java/v0.1.0/task-s2i-java.yaml b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-java/v0.1.0/task-s2i-java.yaml new file mode 100644 index 00000000..c4197786 --- /dev/null +++ b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-java/v0.1.0/task-s2i-java.yaml @@ -0,0 +1,168 @@ +--- +# Source: task-containers/templates/task-s2i-java.yaml +apiVersion: tekton.dev/v1beta1 +kind: Task +metadata: + name: s2i-java + labels: + app.kubernetes.io/version: 0.1.0 + annotations: + tekton.dev/categories: containers + tekton.dev/pipelines.minVersion: 0.38.0 + tekton.dev/tags: containers +spec: + description: | + Builds the source code using the s2i's Java builder-image + "registry.access.redhat.com/ubi8/openjdk-11:latest". + + + workspaces: + - name: source + optional: false + description: | + Application source code, the build context for S2I workflow. + + params: + - name: IMAGE + type: string + description: | + Fully qualified container image name to be built by s2i. + - name: IMAGE_SCRIPTS_URL + type: string + default: image:///usr/libexec/s2i + description: | + Specify a URL containing the default assemble and run scripts for the builder image + - name: ENV_VARS + type: array + default: [] + description: | + Array containing string of Environment Variables as "KEY=VALUE" + - name: SUBDIRECTORY + type: string + default: "." + description: | + Relative subdirectory to the `source` Workspace for the build-context. + - name: STORAGE_DRIVER + type: string + default: overlay + description: | + Set buildah storage driver to reflect the currrent cluster node's + settings. + - name: BUILD_EXTRA_ARGS + type: string + default: "" + description: | + Extra parameters passed for the build command when building images. + - name: PUSH_EXTRA_ARGS + type: string + default: "" + description: | + Extra parameters passed for the push command when pushing images. + - name: SKIP_PUSH + default: "false" + description: | + Skip pushing the image to the container registry. + - name: TLS_VERIFY + type: string + default: "true" + description: | + Sets the TLS verification flag, `true` is recommended. + - name: VERBOSE + type: string + default: "false" + description: | + Turns on verbose logging, all commands executed will be printed out. + + results: + - name: IMAGE_URL + description: | + Fully qualified image name. + - name: IMAGE_DIGEST + description: | + Digest of the image just built. + + stepTemplate: + env: + + - name: PARAMS_IMAGE + value: "$(params.IMAGE)" + - name: PARAMS_IMAGE_SCRIPTS_URL + value: "$(params.IMAGE_SCRIPTS_URL)" + - name: PARAMS_SUBDIRECTORY + value: "$(params.SUBDIRECTORY)" + - name: PARAMS_STORAGE_DRIVER + value: "$(params.STORAGE_DRIVER)" + - name: PARAMS_BUILD_EXTRA_ARGS + value: "$(params.BUILD_EXTRA_ARGS)" + - name: PARAMS_PUSH_EXTRA_ARGS + value: "$(params.PUSH_EXTRA_ARGS)" + - name: PARAMS_SKIP_PUSH + value: "$(params.SKIP_PUSH)" + - name: PARAMS_TLS_VERIFY + value: "$(params.TLS_VERIFY)" + - name: PARAMS_VERBOSE + value: "$(params.VERBOSE)" + - name: WORKSPACES_SOURCE_BOUND + value: "$(workspaces.source.bound)" + - name: WORKSPACES_SOURCE_PATH + value: "$(workspaces.source.path)" + - name: RESULTS_IMAGE_URL_PATH + value: "$(results.IMAGE_URL.path)" + - name: RESULTS_IMAGE_DIGEST_PATH + value: "$(results.IMAGE_DIGEST.path)" + + steps: + - name: load-scripts + image: docker.io/library/bash:latest + workingDir: /scripts + script: | + set -e + printf '%s' "IyEvdXNyL2Jpbi9lbnYgYmFzaAojCiMgV3JhcHBlciBhcm91bmQgImJ1aWxkYWggYnVkIiB0byBidWlsZCBhbmQgcHVzaCBhIGNvbnRhaW5lciBpbWFnZSBiYXNlZCBvbiBhIENvbnRhaW5lcmZpbGUuCiMKCnNob3B0IC1zIGluaGVyaXRfZXJyZXhpdApzZXQgLWV1IC1vIHBpcGVmYWlsCgpzb3VyY2UgIiQoZGlybmFtZSAke0JBU0hfU09VUkNFWzBdfSkvY29tbW9uLnNoIgpzb3VyY2UgIiQoZGlybmFtZSAke0JBU0hfU09VUkNFWzBdfSkvYnVpbGRhaC1jb21tb24uc2giCgpmdW5jdGlvbiBfYnVpbGRhaCgpIHsKICAgIGJ1aWxkYWggXAogICAgICAgIC0tc3RvcmFnZS1kcml2ZXI9IiR7UEFSQU1TX1NUT1JBR0VfRFJJVkVSfSIgXAogICAgICAgIC0tdGxzLXZlcmlmeT0iJHtQQVJBTVNfVExTX1ZFUklGWX0iIFwKICAgICAgICAkeyp9Cn0KCiMKIyBQcmVwYXJlCiMKCiMgbWFraW5nIHN1cmUgdGhlIHJlcXVpcmVkIHdvcmtzcGFjZSAic291cmNlIiBpcyBib3VuZGVkLCB3aGljaCBtZWFucyBpdHMgdm9sdW1lIGlzIGN1cnJlbnRseSBtb3VudGVkCiMgYW5kIHJlYWR5IHRvIHVzZQpwaGFzZSAiSW5zcGVjdGluZyBzb3VyY2Ugd29ya3NwYWNlICcke1dPUktTUEFDRVNfU09VUkNFX1BBVEh9JyAoUFdEPScke1BXRH0nKSIKW1sgIiR7V09SS1NQQUNFU19TT1VSQ0VfQk9VTkR9IiAhPSAidHJ1ZSIgXV0gJiYKICAgIGZhaWwgIldvcm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cy1kb2NrZXJmaWxlICIke1MySV9DT05UQUlORVJGSUxFX1BBVEh9IiBcCiAgICAgICAgLS1lbnZpcm9ubWVudC1maWxlICIke1MySV9FTlZJUk9OTUVOVF9GSUxFfSIKCnBoYXNlICJJbnNwZWN0aW5nIHRoZSBDb250YWluZXJmaWxlIGdlbmVyYXRlZCBhdCAnJHtTMklfQ09OVEFJTkVSRklMRV9QQVRIfSciCltbICEgLWYgIiR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH0iIF1dICYmCiAgICBmYWlsICJHZW5lcmF0ZWQgQ29udGFpbmVyZmlsZSBpcyBub3QgZm91bmQhIgoKc2V0ICt4CnBoYXNlICJHZW5lcmF0ZWQgQ29udGFpbmVyZmlsZSBwYXlsb2FkIgplY2hvIC1lbiAiPj4+ICR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH1cbiQoY2F0ICR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH0pXG48PDwgRU9GXG4iCg==" |base64 -d >s2i-generate.sh + chmod +x s2i-*.sh + volumeMounts: + - name: scripts-dir + mountPath: /scripts + + - name: s2i-generate + image: quay.io/openshift-pipeline/s2i:nightly + workingDir: $(workspaces.source.path) + env: + - name: S2I_BUILDER_IMAGE + value: registry.access.redhat.com/ubi8/openjdk-11:latest + command: + - /scripts/s2i-generate.sh + args: + - "$(params.ENV_VARS[*])" + securityContext: + runAsUser: 0 + volumeMounts: + - name: scripts-dir + mountPath: /scripts + - name: s2i-generate-dir + mountPath: /s2i-generate + + - name: s2i-build + image: registry.access.redhat.com/ubi8/buildah:latest + workingDir: /s2i-generate + command: + - /scripts/s2i-build.sh + securityContext: + privileged: true + volumeMounts: + - name: scripts-dir + mountPath: /scripts + - name: s2i-generate-dir + mountPath: /s2i-generate + + volumes: + - name: scripts-dir + emptyDir: {} + - name: s2i-generate-dir + emptyDir: {} diff --git a/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-nodejs/v0.1.0/README.md b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-nodejs/v0.1.0/README.md new file mode 100644 index 00000000..b86765b3 --- /dev/null +++ b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-nodejs/v0.1.0/README.md @@ -0,0 +1,83 @@ +Source-to-Image Tekton Tasks (`s2i`) +------------------------------------ + +# Abstract + +Describes the Tekton Tasks supporting Source-to-Image for various ecosystems. + +# `s2i` Builder Images + +This section we explain each language ecosystem comes with a predefined set of builder images, supported by Red Hat. + +The `s2i` Task helps in building reproducible container images from source code i.e. task for supporting s2i functionality. + +The s2i Task has been customized with builder images specific to various languages and have been named appropriately as follows: + +| Task Name | Builder Image Used | +| ---------- | ---------------------------------------------------------------------- | +| s2i-python | http://registry.access.redhat.com/ubi8/python-39:latest | +| s2i-go | http://registry.access.redhat.com/ubi8/go-toolset:1.19.10-3 | +| s2i-java | http://registry.access.redhat.com/ubi8/openjdk-11:latest | +| s2i-dotnet | http://registry.access.redhat.com/ubi8/dotnet-60:6.0-37.20230802191230 | +| s2i-php | http://registry.access.redhat.com/ubi9/php-81:1-29 | +| s2i-nodejs | http://registry.access.redhat.com/ubi8/nodejs-18:latest | +| s2i-perl | http://registry.access.redhat.com/ubi9/perl-532:1-91 | +| s2i-ruby | http://registry.access.redhat.com/ubi9/ruby-31:1-50 | + +In case, the above builder images associated with the languages aren’t satisfactory for your source code, you can change it using appropriate parameter. + +# Usage + +Please, consider the usage example below: + +```yaml +--- +apiVersion: tekton.dev/v1beta1 +kind: TaskRun +metadata: {} +spec: + taskRef: + name: s2i-python + params: + - name: IMAGE + value: registry.registry.svc.cluster.local:32222/task-containers/task-s2i-python:latest +``` + +In case the Container Registry requires authentication, please consider the [Tekton Pipelines documentation][tektonPipelineAuth]. In a nutshell, you need to create a Kubernetes Secret describing the following attributes: + +```bash +kubectl create secret docker-registry imagestreams \ + --docker-server="image-registry.openshift-image-registry.svc:5000" \ + --docker-username="${REGISTRY_USERNAME}" \ + --docker-password="${REGISTRY_TOKEN}" +``` + +Then make sure the Secret is linked with the Service-Account running the `TaskRun`/`PipelineRun`. + +## Workspaces + +All of the s2i tasks use the `source` workspace which is meant to contain the Application source code, which acts as the build context for S2I workflow. + + +## Params + +| Param | Type | Default | Description | +| ----------------- | ------ | ------------------------ | ------------------------------------------------------------------------- | +| IMAGE | string | (required) | Fully qualified container image name to be built by s2i | +| IMAGE_SCRIPTS_URL | string | image:///usr/libexec/s2i | URL containing the default assemble and run scripts for the builder image | +| ENV_VARS | array | [] | Array containing string of Environment Variables as "KEY=VALUE” | +| SUBDIRECTORY | string | . | Relative subdirectory to the source Workspace for the build-context. | +| STORAGE_DRIVER | string | overlay | Set buildah storage driver to reflect the currrent cluster node's | +| settings. | +| BUILD_EXTRA_ARGS | string | | Extra parameters passed for the build command when building images. | +| PUSH_EXTRA_ARGS | string | | Extra parameters passed for the push command when pushing images. | +| SKIP_PUSH | string | false | Skip pushing the image to the container registry. | +| TLS_VERIFY | string | true | Sets the TLS verification flag, true is recommended. | +| VERBOSE | string | false | Turns on verbose logging, all commands executed will be printed out. | + +## Results + +| Result | Description | +| ------------ | ------------------------------- | +| IMAGE_URL | Fully qualified image name. | +| IMAGE_DIGEST | Digest of the image just built. | diff --git a/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-nodejs/v0.1.0/task-s2i-nodejs.yaml b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-nodejs/v0.1.0/task-s2i-nodejs.yaml new file mode 100644 index 00000000..f6eab3b7 --- /dev/null +++ b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-nodejs/v0.1.0/task-s2i-nodejs.yaml @@ -0,0 +1,168 @@ +--- +# Source: task-containers/templates/task-s2i-nodejs.yaml +apiVersion: tekton.dev/v1beta1 +kind: Task +metadata: + name: s2i-nodejs + labels: + app.kubernetes.io/version: 0.1.0 + annotations: + tekton.dev/categories: containers + tekton.dev/pipelines.minVersion: 0.38.0 + tekton.dev/tags: containers +spec: + description: | + Builds the source code using the s2i's Nodejs builder-image + "registry.access.redhat.com/ubi8/nodejs-18:latest". + + + workspaces: + - name: source + optional: false + description: | + Application source code, the build context for S2I workflow. + + params: + - name: IMAGE + type: string + description: | + Fully qualified container image name to be built by s2i. + - name: IMAGE_SCRIPTS_URL + type: string + default: image:///usr/libexec/s2i + description: | + Specify a URL containing the default assemble and run scripts for the builder image + - name: ENV_VARS + type: array + default: [] + description: | + Array containing string of Environment Variables as "KEY=VALUE" + - name: SUBDIRECTORY + type: string + default: "." + description: | + Relative subdirectory to the `source` Workspace for the build-context. + - name: STORAGE_DRIVER + type: string + default: overlay + description: | + Set buildah storage driver to reflect the currrent cluster node's + settings. + - name: BUILD_EXTRA_ARGS + type: string + default: "" + description: | + Extra parameters passed for the build command when building images. + - name: PUSH_EXTRA_ARGS + type: string + default: "" + description: | + Extra parameters passed for the push command when pushing images. + - name: SKIP_PUSH + default: "false" + description: | + Skip pushing the image to the container registry. + - name: TLS_VERIFY + type: string + default: "true" + description: | + Sets the TLS verification flag, `true` is recommended. + - name: VERBOSE + type: string + default: "false" + description: | + Turns on verbose logging, all commands executed will be printed out. + + results: + - name: IMAGE_URL + description: | + Fully qualified image name. + - name: IMAGE_DIGEST + description: | + Digest of the image just built. + + stepTemplate: + env: + + - name: PARAMS_IMAGE + value: "$(params.IMAGE)" + - name: PARAMS_IMAGE_SCRIPTS_URL + value: "$(params.IMAGE_SCRIPTS_URL)" + - name: PARAMS_SUBDIRECTORY + value: "$(params.SUBDIRECTORY)" + - name: PARAMS_STORAGE_DRIVER + value: "$(params.STORAGE_DRIVER)" + - name: PARAMS_BUILD_EXTRA_ARGS + value: "$(params.BUILD_EXTRA_ARGS)" + - name: PARAMS_PUSH_EXTRA_ARGS + value: "$(params.PUSH_EXTRA_ARGS)" + - name: PARAMS_SKIP_PUSH + value: "$(params.SKIP_PUSH)" + - name: PARAMS_TLS_VERIFY + value: "$(params.TLS_VERIFY)" + - name: PARAMS_VERBOSE + value: "$(params.VERBOSE)" + - name: WORKSPACES_SOURCE_BOUND + value: "$(workspaces.source.bound)" + - name: WORKSPACES_SOURCE_PATH + value: "$(workspaces.source.path)" + - name: RESULTS_IMAGE_URL_PATH + value: "$(results.IMAGE_URL.path)" + - name: RESULTS_IMAGE_DIGEST_PATH + value: "$(results.IMAGE_DIGEST.path)" + + steps: + - name: load-scripts + image: docker.io/library/bash:latest + workingDir: /scripts + script: | + set -e + printf '%s' "IyEvdXNyL2Jpbi9lbnYgYmFzaAojCiMgV3JhcHBlciBhcm91bmQgImJ1aWxkYWggYnVkIiB0byBidWlsZCBhbmQgcHVzaCBhIGNvbnRhaW5lciBpbWFnZSBiYXNlZCBvbiBhIENvbnRhaW5lcmZpbGUuCiMKCnNob3B0IC1zIGluaGVyaXRfZXJyZXhpdApzZXQgLWV1IC1vIHBpcGVmYWlsCgpzb3VyY2UgIiQoZGlybmFtZSAke0JBU0hfU09VUkNFWzBdfSkvY29tbW9uLnNoIgpzb3VyY2UgIiQoZGlybmFtZSAke0JBU0hfU09VUkNFWzBdfSkvYnVpbGRhaC1jb21tb24uc2giCgpmdW5jdGlvbiBfYnVpbGRhaCgpIHsKICAgIGJ1aWxkYWggXAogICAgICAgIC0tc3RvcmFnZS1kcml2ZXI9IiR7UEFSQU1TX1NUT1JBR0VfRFJJVkVSfSIgXAogICAgICAgIC0tdGxzLXZlcmlmeT0iJHtQQVJBTVNfVExTX1ZFUklGWX0iIFwKICAgICAgICAkeyp9Cn0KCiMKIyBQcmVwYXJlCiMKCiMgbWFraW5nIHN1cmUgdGhlIHJlcXVpcmVkIHdvcmtzcGFjZSAic291cmNlIiBpcyBib3VuZGVkLCB3aGljaCBtZWFucyBpdHMgdm9sdW1lIGlzIGN1cnJlbnRseSBtb3VudGVkCiMgYW5kIHJlYWR5IHRvIHVzZQpwaGFzZSAiSW5zcGVjdGluZyBzb3VyY2Ugd29ya3NwYWNlICcke1dPUktTUEFDRVNfU09VUkNFX1BBVEh9JyAoUFdEPScke1BXRH0nKSIKW1sgIiR7V09SS1NQQUNFU19T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VybCAiJHtQQVJBTVNfSU1BR0VfU0NSSVBUU19VUkx9IiBcCiAgICAgICAgLS1hcy1kb2NrZXJmaWxlICIke1MySV9DT05UQUlORVJGSUxFX1BBVEh9IiBcCiAgICAgICAgLS1lbnZpcm9ubWVudC1maWxlICIke1MySV9FTlZJUk9OTUVOVF9GSUxFfSIKCnBoYXNlICJJbnNwZWN0aW5nIHRoZSBDb250YWluZXJmaWxlIGdlbmVyYXRlZCBhdCAnJHtTMklfQ09OVEFJTkVSRklMRV9QQVRIfSciCltbICEgLWYgIiR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH0iIF1dICYmCiAgICBmYWlsICJHZW5lcmF0ZWQgQ29udGFpbmVyZmlsZSBpcyBub3QgZm91bmQhIgoKc2V0ICt4CnBoYXNlICJHZW5lcmF0ZWQgQ29udGFpbmVyZmlsZSBwYXlsb2FkIgplY2hvIC1lbiAiPj4+ICR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH1cbiQoY2F0ICR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH0pXG48PDwgRU9GXG4iCg==" |base64 -d >s2i-generate.sh + chmod +x s2i-*.sh + volumeMounts: + - name: scripts-dir + mountPath: /scripts + + - name: s2i-generate + image: quay.io/openshift-pipeline/s2i:nightly + workingDir: $(workspaces.source.path) + env: + - name: S2I_BUILDER_IMAGE + value: registry.access.redhat.com/ubi8/nodejs-18:latest + command: + - /scripts/s2i-generate.sh + args: + - "$(params.ENV_VARS[*])" + securityContext: + runAsUser: 0 + volumeMounts: + - name: scripts-dir + mountPath: /scripts + - name: s2i-generate-dir + mountPath: /s2i-generate + + - name: s2i-build + image: registry.access.redhat.com/ubi8/buildah:latest + workingDir: /s2i-generate + command: + - /scripts/s2i-build.sh + securityContext: + privileged: true + volumeMounts: + - name: scripts-dir + mountPath: /scripts + - name: s2i-generate-dir + mountPath: /s2i-generate + + volumes: + - name: scripts-dir + emptyDir: {} + - name: s2i-generate-dir + emptyDir: {} diff --git a/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-perl/v0.1.0/README.md b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-perl/v0.1.0/README.md new file mode 100644 index 00000000..b86765b3 --- /dev/null +++ b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-perl/v0.1.0/README.md @@ -0,0 +1,83 @@ +Source-to-Image Tekton Tasks (`s2i`) +------------------------------------ + +# Abstract + +Describes the Tekton Tasks supporting Source-to-Image for various ecosystems. + +# `s2i` Builder Images + +This section we explain each language ecosystem comes with a predefined set of builder images, supported by Red Hat. + +The `s2i` Task helps in building reproducible container images from source code i.e. task for supporting s2i functionality. + +The s2i Task has been customized with builder images specific to various languages and have been named appropriately as follows: + +| Task Name | Builder Image Used | +| ---------- | ---------------------------------------------------------------------- | +| s2i-python | http://registry.access.redhat.com/ubi8/python-39:latest | +| s2i-go | http://registry.access.redhat.com/ubi8/go-toolset:1.19.10-3 | +| s2i-java | http://registry.access.redhat.com/ubi8/openjdk-11:latest | +| s2i-dotnet | http://registry.access.redhat.com/ubi8/dotnet-60:6.0-37.20230802191230 | +| s2i-php | http://registry.access.redhat.com/ubi9/php-81:1-29 | +| s2i-nodejs | http://registry.access.redhat.com/ubi8/nodejs-18:latest | +| s2i-perl | http://registry.access.redhat.com/ubi9/perl-532:1-91 | +| s2i-ruby | http://registry.access.redhat.com/ubi9/ruby-31:1-50 | + +In case, the above builder images associated with the languages aren’t satisfactory for your source code, you can change it using appropriate parameter. + +# Usage + +Please, consider the usage example below: + +```yaml +--- +apiVersion: tekton.dev/v1beta1 +kind: TaskRun +metadata: {} +spec: + taskRef: + name: s2i-python + params: + - name: IMAGE + value: registry.registry.svc.cluster.local:32222/task-containers/task-s2i-python:latest +``` + +In case the Container Registry requires authentication, please consider the [Tekton Pipelines documentation][tektonPipelineAuth]. In a nutshell, you need to create a Kubernetes Secret describing the following attributes: + +```bash +kubectl create secret docker-registry imagestreams \ + --docker-server="image-registry.openshift-image-registry.svc:5000" \ + --docker-username="${REGISTRY_USERNAME}" \ + --docker-password="${REGISTRY_TOKEN}" +``` + +Then make sure the Secret is linked with the Service-Account running the `TaskRun`/`PipelineRun`. + +## Workspaces + +All of the s2i tasks use the `source` workspace which is meant to contain the Application source code, which acts as the build context for S2I workflow. + + +## Params + +| Param | Type | Default | Description | +| ----------------- | ------ | ------------------------ | ------------------------------------------------------------------------- | +| IMAGE | string | (required) | Fully qualified container image name to be built by s2i | +| IMAGE_SCRIPTS_URL | string | image:///usr/libexec/s2i | URL containing the default assemble and run scripts for the builder image | +| ENV_VARS | array | [] | Array containing string of Environment Variables as "KEY=VALUE” | +| SUBDIRECTORY | string | . | Relative subdirectory to the source Workspace for the build-context. | +| STORAGE_DRIVER | string | overlay | Set buildah storage driver to reflect the currrent cluster node's | +| settings. | +| BUILD_EXTRA_ARGS | string | | Extra parameters passed for the build command when building images. | +| PUSH_EXTRA_ARGS | string | | Extra parameters passed for the push command when pushing images. | +| SKIP_PUSH | string | false | Skip pushing the image to the container registry. | +| TLS_VERIFY | string | true | Sets the TLS verification flag, true is recommended. | +| VERBOSE | string | false | Turns on verbose logging, all commands executed will be printed out. | + +## Results + +| Result | Description | +| ------------ | ------------------------------- | +| IMAGE_URL | Fully qualified image name. | +| IMAGE_DIGEST | Digest of the image just built. | diff --git a/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-perl/v0.1.0/task-s2i-perl.yaml b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-perl/v0.1.0/task-s2i-perl.yaml new file mode 100644 index 00000000..9b1eef40 --- /dev/null +++ b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-perl/v0.1.0/task-s2i-perl.yaml @@ -0,0 +1,168 @@ +--- +# Source: task-containers/templates/task-s2i-perl.yaml +apiVersion: tekton.dev/v1beta1 +kind: Task +metadata: + name: s2i-perl + labels: + app.kubernetes.io/version: 0.1.0 + annotations: + tekton.dev/categories: containers + tekton.dev/pipelines.minVersion: 0.38.0 + tekton.dev/tags: containers +spec: + description: | + Builds the source code using the s2i's Perl builder-image + "registry.access.redhat.com/ubi9/perl-532:1-91". + + + workspaces: + - name: source + optional: false + description: | + Application source code, the build context for S2I workflow. + + params: + - name: IMAGE + type: string + description: | + Fully qualified container image name to be built by s2i. + - name: IMAGE_SCRIPTS_URL + type: string + default: image:///usr/libexec/s2i + description: | + Specify a URL containing the default assemble and run scripts for the builder image + - name: ENV_VARS + type: array + default: [] + description: | + Array containing string of Environment Variables as "KEY=VALUE" + - name: SUBDIRECTORY + type: string + default: "." + description: | + Relative subdirectory to the `source` Workspace for the build-context. + - name: STORAGE_DRIVER + type: string + default: overlay + description: | + Set buildah storage driver to reflect the currrent cluster node's + settings. + - name: BUILD_EXTRA_ARGS + type: string + default: "" + description: | + Extra parameters passed for the build command when building images. + - name: PUSH_EXTRA_ARGS + type: string + default: "" + description: | + Extra parameters passed for the push command when pushing images. + - name: SKIP_PUSH + default: "false" + description: | + Skip pushing the image to the container registry. + - name: TLS_VERIFY + type: string + default: "true" + description: | + Sets the TLS verification flag, `true` is recommended. + - name: VERBOSE + type: string + default: "false" + description: | + Turns on verbose logging, all commands executed will be printed out. + + results: + - name: IMAGE_URL + description: | + Fully qualified image name. + - name: IMAGE_DIGEST + description: | + Digest of the image just built. + + stepTemplate: + env: + + - name: PARAMS_IMAGE + value: "$(params.IMAGE)" + - name: PARAMS_IMAGE_SCRIPTS_URL + value: "$(params.IMAGE_SCRIPTS_URL)" + - name: PARAMS_SUBDIRECTORY + value: "$(params.SUBDIRECTORY)" + - name: PARAMS_STORAGE_DRIVER + value: "$(params.STORAGE_DRIVER)" + - name: PARAMS_BUILD_EXTRA_ARGS + value: "$(params.BUILD_EXTRA_ARGS)" + - name: PARAMS_PUSH_EXTRA_ARGS + value: "$(params.PUSH_EXTRA_ARGS)" + - name: PARAMS_SKIP_PUSH + value: "$(params.SKIP_PUSH)" + - name: PARAMS_TLS_VERIFY + value: "$(params.TLS_VERIFY)" + - name: PARAMS_VERBOSE + value: "$(params.VERBOSE)" + - name: WORKSPACES_SOURCE_BOUND + value: "$(workspaces.source.bound)" + - name: WORKSPACES_SOURCE_PATH + value: "$(workspaces.source.path)" + - name: RESULTS_IMAGE_URL_PATH + value: "$(results.IMAGE_URL.path)" + - name: RESULTS_IMAGE_DIGEST_PATH + value: "$(results.IMAGE_DIGEST.path)" + + steps: + - name: load-scripts + image: docker.io/library/bash:latest + workingDir: /scripts + script: | + set -e + printf '%s' "IyEvdXNyL2Jpbi9lbnYgYmFzaAojCiMgV3JhcHBlciBhcm91bmQgImJ1aWxkYWggYnVkIiB0byBidWlsZCBhbmQgcHVzaCBhIGNvbnRhaW5lciBpbWFnZSBiYXNlZCBvbiBhIENvbnRhaW5lcmZpbGUuCiMKCnNob3B0IC1zIGluaGVyaXRfZXJyZXhpdApzZXQgLWV1IC1vIHBpcGVmYWlsCgpzb3VyY2UgIiQoZGlybmFtZSAke0JBU0hfU09VUkNFWzBdfSkvY29tbW9uLnNoIgpzb3VyY2UgIiQoZGlybmFtZSAke0JBU0hfU09VUkNFWzBdfSkvYnVpbGRhaC1jb21tb24uc2giCgpmdW5jdGlvbiBfYnVpbGRhaCgpIHsKICAgIGJ1aWxkYWggXAogICAgICAgIC0tc3RvcmFnZS1kcml2ZXI9IiR7UEFSQU1TX1NUT1JBR0VfRFJJVkVSfSIgXAogICAgICAgIC0tdGxzLXZlcmlmeT0iJHtQQVJBTVNfVExTX1ZFUklGWX0iIFwKICAgICAgICAkeyp9Cn0KCiMKIyBQcmVwYXJlCiMKCiMgbWFraW5nIHN1cmUgdGhlIHJlcXVpcmVkIHdvcmtzcGFjZSAic291cmNlIiBpcyBib3VuZGVkLCB3aGljaCBtZWFucyBpdHMgdm9sdW1lIGlzIGN1cnJlbnRseSBtb3VudGVkCiMgYW5kIHJlYWR5IHRvIHVzZQpwaGFzZSAiSW5zcGVjdGluZyBzb3VyY2Ugd29ya3NwYWNlICcke1dPUktTUEFDRVNfU09VUkNFX1BBVEh9JyAoUFdEPScke1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CiAgICAgICAgLS1pbWFnZS1zY3JpcHRzLXVybCAiJHtQQVJBTVNfSU1BR0VfU0NSSVBUU19VUkx9IiBcCiAgICAgICAgLS1hcy1kb2NrZXJmaWxlICIke1MySV9DT05UQUlORVJGSUxFX1BBVEh9IiBcCiAgICAgICAgLS1lbnZpcm9ubWVudC1maWxlICIke1MySV9FTlZJUk9OTUVOVF9GSUxFfSIKCnBoYXNlICJJbnNwZWN0aW5nIHRoZSBDb250YWluZXJmaWxlIGdlbmVyYXRlZCBhdCAnJHtTMklfQ09OVEFJTkVSRklMRV9QQVRIfSciCltbICEgLWYgIiR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH0iIF1dICYmCiAgICBmYWlsICJHZW5lcmF0ZWQgQ29udGFpbmVyZmlsZSBpcyBub3QgZm91bmQhIgoKc2V0ICt4CnBoYXNlICJHZW5lcmF0ZWQgQ29udGFpbmVyZmlsZSBwYXlsb2FkIgplY2hvIC1lbiAiPj4+ICR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH1cbiQoY2F0ICR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH0pXG48PDwgRU9GXG4iCg==" |base64 -d >s2i-generate.sh + chmod +x s2i-*.sh + volumeMounts: + - name: scripts-dir + mountPath: /scripts + + - name: s2i-generate + image: quay.io/openshift-pipeline/s2i:nightly + workingDir: $(workspaces.source.path) + env: + - name: S2I_BUILDER_IMAGE + value: registry.access.redhat.com/ubi9/perl-532:1-91 + command: + - /scripts/s2i-generate.sh + args: + - "$(params.ENV_VARS[*])" + securityContext: + runAsUser: 0 + volumeMounts: + - name: scripts-dir + mountPath: /scripts + - name: s2i-generate-dir + mountPath: /s2i-generate + + - name: s2i-build + image: registry.access.redhat.com/ubi8/buildah:latest + workingDir: /s2i-generate + command: + - /scripts/s2i-build.sh + securityContext: + privileged: true + volumeMounts: + - name: scripts-dir + mountPath: /scripts + - name: s2i-generate-dir + mountPath: /s2i-generate + + volumes: + - name: scripts-dir + emptyDir: {} + - name: s2i-generate-dir + emptyDir: {} diff --git a/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-php/v0.1.0/README.md b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-php/v0.1.0/README.md new file mode 100644 index 00000000..b86765b3 --- /dev/null +++ b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-php/v0.1.0/README.md @@ -0,0 +1,83 @@ +Source-to-Image Tekton Tasks (`s2i`) +------------------------------------ + +# Abstract + +Describes the Tekton Tasks supporting Source-to-Image for various ecosystems. + +# `s2i` Builder Images + +This section we explain each language ecosystem comes with a predefined set of builder images, supported by Red Hat. + +The `s2i` Task helps in building reproducible container images from source code i.e. task for supporting s2i functionality. + +The s2i Task has been customized with builder images specific to various languages and have been named appropriately as follows: + +| Task Name | Builder Image Used | +| ---------- | ---------------------------------------------------------------------- | +| s2i-python | http://registry.access.redhat.com/ubi8/python-39:latest | +| s2i-go | http://registry.access.redhat.com/ubi8/go-toolset:1.19.10-3 | +| s2i-java | http://registry.access.redhat.com/ubi8/openjdk-11:latest | +| s2i-dotnet | http://registry.access.redhat.com/ubi8/dotnet-60:6.0-37.20230802191230 | +| s2i-php | http://registry.access.redhat.com/ubi9/php-81:1-29 | +| s2i-nodejs | http://registry.access.redhat.com/ubi8/nodejs-18:latest | +| s2i-perl | http://registry.access.redhat.com/ubi9/perl-532:1-91 | +| s2i-ruby | http://registry.access.redhat.com/ubi9/ruby-31:1-50 | + +In case, the above builder images associated with the languages aren’t satisfactory for your source code, you can change it using appropriate parameter. + +# Usage + +Please, consider the usage example below: + +```yaml +--- +apiVersion: tekton.dev/v1beta1 +kind: TaskRun +metadata: {} +spec: + taskRef: + name: s2i-python + params: + - name: IMAGE + value: registry.registry.svc.cluster.local:32222/task-containers/task-s2i-python:latest +``` + +In case the Container Registry requires authentication, please consider the [Tekton Pipelines documentation][tektonPipelineAuth]. In a nutshell, you need to create a Kubernetes Secret describing the following attributes: + +```bash +kubectl create secret docker-registry imagestreams \ + --docker-server="image-registry.openshift-image-registry.svc:5000" \ + --docker-username="${REGISTRY_USERNAME}" \ + --docker-password="${REGISTRY_TOKEN}" +``` + +Then make sure the Secret is linked with the Service-Account running the `TaskRun`/`PipelineRun`. + +## Workspaces + +All of the s2i tasks use the `source` workspace which is meant to contain the Application source code, which acts as the build context for S2I workflow. + + +## Params + +| Param | Type | Default | Description | +| ----------------- | ------ | ------------------------ | ------------------------------------------------------------------------- | +| IMAGE | string | (required) | Fully qualified container image name to be built by s2i | +| IMAGE_SCRIPTS_URL | string | image:///usr/libexec/s2i | URL containing the default assemble and run scripts for the builder image | +| ENV_VARS | array | [] | Array containing string of Environment Variables as "KEY=VALUE” | +| SUBDIRECTORY | string | . | Relative subdirectory to the source Workspace for the build-context. | +| STORAGE_DRIVER | string | overlay | Set buildah storage driver to reflect the currrent cluster node's | +| settings. | +| BUILD_EXTRA_ARGS | string | | Extra parameters passed for the build command when building images. | +| PUSH_EXTRA_ARGS | string | | Extra parameters passed for the push command when pushing images. | +| SKIP_PUSH | string | false | Skip pushing the image to the container registry. | +| TLS_VERIFY | string | true | Sets the TLS verification flag, true is recommended. | +| VERBOSE | string | false | Turns on verbose logging, all commands executed will be printed out. | + +## Results + +| Result | Description | +| ------------ | ------------------------------- | +| IMAGE_URL | Fully qualified image name. | +| IMAGE_DIGEST | Digest of the image just built. | diff --git a/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-php/v0.1.0/task-s2i-php.yaml b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-php/v0.1.0/task-s2i-php.yaml new file mode 100644 index 00000000..ed7ce755 --- /dev/null +++ b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-php/v0.1.0/task-s2i-php.yaml @@ -0,0 +1,168 @@ +--- +# Source: task-containers/templates/task-s2i-php.yaml +apiVersion: tekton.dev/v1beta1 +kind: Task +metadata: + name: s2i-php + labels: + app.kubernetes.io/version: 0.1.0 + annotations: + tekton.dev/categories: containers + tekton.dev/pipelines.minVersion: 0.38.0 + tekton.dev/tags: containers +spec: + description: | + Builds the source code using the s2i's php builder-image + "registry.access.redhat.com/ubi9/php-81:1-29". + + + workspaces: + - name: source + optional: false + description: | + Application source code, the build context for S2I workflow. + + params: + - name: IMAGE + type: string + description: | + Fully qualified container image name to be built by s2i. + - name: IMAGE_SCRIPTS_URL + type: string + default: image:///usr/libexec/s2i + description: | + Specify a URL containing the default assemble and run scripts for the builder image + - name: ENV_VARS + type: array + default: [] + description: | + Array containing string of Environment Variables as "KEY=VALUE" + - name: SUBDIRECTORY + type: string + default: "." + description: | + Relative subdirectory to the `source` Workspace for the build-context. + - name: STORAGE_DRIVER + type: string + default: overlay + description: | + Set buildah storage driver to reflect the currrent cluster node's + settings. + - name: BUILD_EXTRA_ARGS + type: string + default: "" + description: | + Extra parameters passed for the build command when building images. + - name: PUSH_EXTRA_ARGS + type: string + default: "" + description: | + Extra parameters passed for the push command when pushing images. + - name: SKIP_PUSH + default: "false" + description: | + Skip pushing the image to the container registry. + - name: TLS_VERIFY + type: string + default: "true" + description: | + Sets the TLS verification flag, `true` is recommended. + - name: VERBOSE + type: string + default: "false" + description: | + Turns on verbose logging, all commands executed will be printed out. + + results: + - name: IMAGE_URL + description: | + Fully qualified image name. + - name: IMAGE_DIGEST + description: | + Digest of the image just built. + + stepTemplate: + env: + + - name: PARAMS_IMAGE + value: "$(params.IMAGE)" + - name: PARAMS_IMAGE_SCRIPTS_URL + value: "$(params.IMAGE_SCRIPTS_URL)" + - name: PARAMS_SUBDIRECTORY + value: "$(params.SUBDIRECTORY)" + - name: PARAMS_STORAGE_DRIVER + value: "$(params.STORAGE_DRIVER)" + - name: PARAMS_BUILD_EXTRA_ARGS + value: "$(params.BUILD_EXTRA_ARGS)" + - name: PARAMS_PUSH_EXTRA_ARGS + value: "$(params.PUSH_EXTRA_ARGS)" + - name: PARAMS_SKIP_PUSH + value: "$(params.SKIP_PUSH)" + - name: PARAMS_TLS_VERIFY + value: "$(params.TLS_VERIFY)" + - name: PARAMS_VERBOSE + value: "$(params.VERBOSE)" + - name: WORKSPACES_SOURCE_BOUND + value: "$(workspaces.source.bound)" + - name: WORKSPACES_SOURCE_PATH + value: "$(workspaces.source.path)" + - name: RESULTS_IMAGE_URL_PATH + value: "$(results.IMAGE_URL.path)" + - name: RESULTS_IMAGE_DIGEST_PATH + value: "$(results.IMAGE_DIGEST.path)" + + steps: + - name: load-scripts + image: docker.io/library/bash:latest + workingDir: /scripts + script: | + set -e + printf '%s' "IyEvdXNyL2Jpbi9lbnYgYmFzaAojCiMgV3JhcHBlciBhcm91bmQgImJ1aWxkYWggYnVkIiB0byBidWlsZCBhbmQgcHVzaCBhIGNvbnRhaW5lciBpbWFnZSBiYXNlZCBvbiBhIENvbnRhaW5lcmZpbGUuCiMKCnNob3B0IC1zIGluaGVyaXRfZXJyZXhpdApzZXQgLWV1IC1vIHBpcGVmYWlsCgpzb3VyY2UgIiQoZGlybmFtZSAke0JBU0hfU09VUkNFWzBdfSkvY29tbW9uLnNoIgpzb3VyY2UgIiQoZGlybmFtZSAke0JBU0hfU09VUkNFWzBdfSkvYnVpbGRhaC1jb21tb24uc2giCgpmdW5jdGlvbiBfYnVpbGRhaCgpIHsKICAgIGJ1aWxkYWggXAogICAgICAgIC0tc3RvcmFnZS1kcml2ZXI9IiR7UEFSQU1TX1NUT1JBR0VfRFJJVkVSfSIgXAogICAgICAgIC0tdGxzLXZlcmlmeT0iJHtQQVJBTVNfVExTX1ZFUklGWX0iIFwKICAgICAgICAkeyp9Cn0KCiMKIyBQcmVwYXJlCiMKCiMgbWFraW5nIHN1cmUgdGhlIHJlcXVpcmVkIHdvcmtzcGFjZSAic291cmNlIiBpcyBib3VuZGVkLCB3aGljaCBtZWFucyBpdHMgdm9sdW1lIGlzIGN1cnJlbnRseSBtb3VudGVkCiMgYW5kIHJlYWR5IHRvIHVzZQpwaGFzZSAiSW5zcGVjdGluZyBzb3VyY2Ugd29ya3NwYWNlICcke1dPUktTUEFDRVNfU09VUkNFX1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UxERVJfSU1BR0V9IiBcCiAgICAgICAgLS1pbWFnZS1zY3JpcHRzLXVybCAiJHtQQVJBTVNfSU1BR0VfU0NSSVBUU19VUkx9IiBcCiAgICAgICAgLS1hcy1kb2NrZXJmaWxlICIke1MySV9DT05UQUlORVJGSUxFX1BBVEh9IiBcCiAgICAgICAgLS1lbnZpcm9ubWVudC1maWxlICIke1MySV9FTlZJUk9OTUVOVF9GSUxFfSIKCnBoYXNlICJJbnNwZWN0aW5nIHRoZSBDb250YWluZXJmaWxlIGdlbmVyYXRlZCBhdCAnJHtTMklfQ09OVEFJTkVSRklMRV9QQVRIfSciCltbICEgLWYgIiR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH0iIF1dICYmCiAgICBmYWlsICJHZW5lcmF0ZWQgQ29udGFpbmVyZmlsZSBpcyBub3QgZm91bmQhIgoKc2V0ICt4CnBoYXNlICJHZW5lcmF0ZWQgQ29udGFpbmVyZmlsZSBwYXlsb2FkIgplY2hvIC1lbiAiPj4+ICR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH1cbiQoY2F0ICR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH0pXG48PDwgRU9GXG4iCg==" |base64 -d >s2i-generate.sh + chmod +x s2i-*.sh + volumeMounts: + - name: scripts-dir + mountPath: /scripts + + - name: s2i-generate + image: quay.io/openshift-pipeline/s2i:nightly + workingDir: $(workspaces.source.path) + env: + - name: S2I_BUILDER_IMAGE + value: registry.access.redhat.com/ubi9/php-81:1-29 + command: + - /scripts/s2i-generate.sh + args: + - "$(params.ENV_VARS[*])" + securityContext: + runAsUser: 0 + volumeMounts: + - name: scripts-dir + mountPath: /scripts + - name: s2i-generate-dir + mountPath: /s2i-generate + + - name: s2i-build + image: registry.access.redhat.com/ubi8/buildah:latest + workingDir: /s2i-generate + command: + - /scripts/s2i-build.sh + securityContext: + privileged: true + volumeMounts: + - name: scripts-dir + mountPath: /scripts + - name: s2i-generate-dir + mountPath: /s2i-generate + + volumes: + - name: scripts-dir + emptyDir: {} + - name: s2i-generate-dir + emptyDir: {} diff --git a/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-python/v0.1.0/README.md b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-python/v0.1.0/README.md new file mode 100644 index 00000000..b86765b3 --- /dev/null +++ b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-python/v0.1.0/README.md @@ -0,0 +1,83 @@ +Source-to-Image Tekton Tasks (`s2i`) +------------------------------------ + +# Abstract + +Describes the Tekton Tasks supporting Source-to-Image for various ecosystems. + +# `s2i` Builder Images + +This section we explain each language ecosystem comes with a predefined set of builder images, supported by Red Hat. + +The `s2i` Task helps in building reproducible container images from source code i.e. task for supporting s2i functionality. + +The s2i Task has been customized with builder images specific to various languages and have been named appropriately as follows: + +| Task Name | Builder Image Used | +| ---------- | ---------------------------------------------------------------------- | +| s2i-python | http://registry.access.redhat.com/ubi8/python-39:latest | +| s2i-go | http://registry.access.redhat.com/ubi8/go-toolset:1.19.10-3 | +| s2i-java | http://registry.access.redhat.com/ubi8/openjdk-11:latest | +| s2i-dotnet | http://registry.access.redhat.com/ubi8/dotnet-60:6.0-37.20230802191230 | +| s2i-php | http://registry.access.redhat.com/ubi9/php-81:1-29 | +| s2i-nodejs | http://registry.access.redhat.com/ubi8/nodejs-18:latest | +| s2i-perl | http://registry.access.redhat.com/ubi9/perl-532:1-91 | +| s2i-ruby | http://registry.access.redhat.com/ubi9/ruby-31:1-50 | + +In case, the above builder images associated with the languages aren’t satisfactory for your source code, you can change it using appropriate parameter. + +# Usage + +Please, consider the usage example below: + +```yaml +--- +apiVersion: tekton.dev/v1beta1 +kind: TaskRun +metadata: {} +spec: + taskRef: + name: s2i-python + params: + - name: IMAGE + value: registry.registry.svc.cluster.local:32222/task-containers/task-s2i-python:latest +``` + +In case the Container Registry requires authentication, please consider the [Tekton Pipelines documentation][tektonPipelineAuth]. In a nutshell, you need to create a Kubernetes Secret describing the following attributes: + +```bash +kubectl create secret docker-registry imagestreams \ + --docker-server="image-registry.openshift-image-registry.svc:5000" \ + --docker-username="${REGISTRY_USERNAME}" \ + --docker-password="${REGISTRY_TOKEN}" +``` + +Then make sure the Secret is linked with the Service-Account running the `TaskRun`/`PipelineRun`. + +## Workspaces + +All of the s2i tasks use the `source` workspace which is meant to contain the Application source code, which acts as the build context for S2I workflow. + + +## Params + +| Param | Type | Default | Description | +| ----------------- | ------ | ------------------------ | ------------------------------------------------------------------------- | +| IMAGE | string | (required) | Fully qualified container image name to be built by s2i | +| IMAGE_SCRIPTS_URL | string | image:///usr/libexec/s2i | URL containing the default assemble and run scripts for the builder image | +| ENV_VARS | array | [] | Array containing string of Environment Variables as "KEY=VALUE” | +| SUBDIRECTORY | string | . | Relative subdirectory to the source Workspace for the build-context. | +| STORAGE_DRIVER | string | overlay | Set buildah storage driver to reflect the currrent cluster node's | +| settings. | +| BUILD_EXTRA_ARGS | string | | Extra parameters passed for the build command when building images. | +| PUSH_EXTRA_ARGS | string | | Extra parameters passed for the push command when pushing images. | +| SKIP_PUSH | string | false | Skip pushing the image to the container registry. | +| TLS_VERIFY | string | true | Sets the TLS verification flag, true is recommended. | +| VERBOSE | string | false | Turns on verbose logging, all commands executed will be printed out. | + +## Results + +| Result | Description | +| ------------ | ------------------------------- | +| IMAGE_URL | Fully qualified image name. | +| IMAGE_DIGEST | Digest of the image just built. | diff --git a/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-python/v0.1.0/task-s2i-python.yaml b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-python/v0.1.0/task-s2i-python.yaml new file mode 100644 index 00000000..4b697755 --- /dev/null +++ b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-python/v0.1.0/task-s2i-python.yaml @@ -0,0 +1,168 @@ +--- +# Source: task-containers/templates/task-s2i-python.yaml +apiVersion: tekton.dev/v1beta1 +kind: Task +metadata: + name: s2i-python + labels: + app.kubernetes.io/version: 0.1.0 + annotations: + tekton.dev/categories: containers + tekton.dev/pipelines.minVersion: 0.38.0 + tekton.dev/tags: containers +spec: + description: | + Builds the source code using the s2i's Python builder-image + "registry.access.redhat.com/ubi8/python-39:latest". + + + workspaces: + - name: source + optional: false + description: | + Application source code, the build context for S2I workflow. + + params: + - name: IMAGE + type: string + description: | + Fully qualified container image name to be built by s2i. + - name: IMAGE_SCRIPTS_URL + type: string + default: image:///usr/libexec/s2i + description: | + Specify a URL containing the default assemble and run scripts for the builder image + - name: ENV_VARS + type: array + default: [] + description: | + Array containing string of Environment Variables as "KEY=VALUE" + - name: SUBDIRECTORY + type: string + default: "." + description: | + Relative subdirectory to the `source` Workspace for the build-context. + - name: STORAGE_DRIVER + type: string + default: overlay + description: | + Set buildah storage driver to reflect the currrent cluster node's + settings. + - name: BUILD_EXTRA_ARGS + type: string + default: "" + description: | + Extra parameters passed for the build command when building images. + - name: PUSH_EXTRA_ARGS + type: string + default: "" + description: | + Extra parameters passed for the push command when pushing images. + - name: SKIP_PUSH + default: "false" + description: | + Skip pushing the image to the container registry. + - name: TLS_VERIFY + type: string + default: "true" + description: | + Sets the TLS verification flag, `true` is recommended. + - name: VERBOSE + type: string + default: "false" + description: | + Turns on verbose logging, all commands executed will be printed out. + + results: + - name: IMAGE_URL + description: | + Fully qualified image name. + - name: IMAGE_DIGEST + description: | + Digest of the image just built. + + stepTemplate: + env: + + - name: PARAMS_IMAGE + value: "$(params.IMAGE)" + - name: PARAMS_IMAGE_SCRIPTS_URL + value: "$(params.IMAGE_SCRIPTS_URL)" + - name: PARAMS_SUBDIRECTORY + value: "$(params.SUBDIRECTORY)" + - name: PARAMS_STORAGE_DRIVER + value: "$(params.STORAGE_DRIVER)" + - name: PARAMS_BUILD_EXTRA_ARGS + value: "$(params.BUILD_EXTRA_ARGS)" + - name: PARAMS_PUSH_EXTRA_ARGS + value: "$(params.PUSH_EXTRA_ARGS)" + - name: PARAMS_SKIP_PUSH + value: "$(params.SKIP_PUSH)" + - name: PARAMS_TLS_VERIFY + value: "$(params.TLS_VERIFY)" + - name: PARAMS_VERBOSE + value: "$(params.VERBOSE)" + - name: WORKSPACES_SOURCE_BOUND + value: "$(workspaces.source.bound)" + - name: WORKSPACES_SOURCE_PATH + value: "$(workspaces.source.path)" + - name: RESULTS_IMAGE_URL_PATH + value: "$(results.IMAGE_URL.path)" + - name: RESULTS_IMAGE_DIGEST_PATH + value: "$(results.IMAGE_DIGEST.path)" + + steps: + - name: load-scripts + image: docker.io/library/bash:latest + workingDir: /scripts + script: | + set -e + printf '%s' "IyEvdXNyL2Jpbi9lbnYgYmFzaAojCiMgV3JhcHBlciBhcm91bmQgImJ1aWxkYWggYnVkIiB0byBidWlsZCBhbmQgcHVzaCBhIGNvbnRhaW5lciBpbWFnZSBiYXNlZCBvbiBhIENvbnRhaW5lcmZpbGUuCiMKCnNob3B0IC1zIGluaGVyaXRfZXJyZXhpdApzZXQgLWV1IC1vIHBpcGVmYWlsCgpzb3VyY2UgIiQoZGlybmFtZSAke0JBU0hfU09VUkNFWzBdfSkvY29tbW9uLnNoIgpzb3VyY2UgIiQoZGlybmFtZSAke0JBU0hfU09VUkNFWzBdfSkvYnVpbGRhaC1jb21tb24uc2giCgpmdW5jdGlvbiBfYnVpbGRhaCgpIHsKICAgIGJ1aWxkYWggXAogICAgICAgIC0tc3RvcmFnZS1kcml2ZXI9IiR7UEFSQU1TX1NUT1JBR0VfRFJJVkVSfSIgXAogICAgICAgIC0tdGxzLXZlcmlmeT0iJHtQQVJBTVNfVExTX1ZFUklGWX0iIFwKICAgICAgICAkeyp9Cn0KCiMKIyBQcmVwYXJlCiMKCiMgbWFraW5nIHN1cmUgdGhlIHJlcXVpcmVkIHdvcmtzcGFjZSAic291cmNlIiBpcyBib3VuZGVkLCB3aGljaCBtZWFucyBpdHMgdm9sdW1lIGlzIGN1cnJlbnRseSBtb3VudGVkCiMgYW5kIHJlYWR5IHRvIHVzZQpwaGFzZSAiSW5zcGVjdGluZyBzb3VyY2Ugd29ya3NwYWNlICcke1dPUktTUE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IgIiR7UzJJX0JVSUxERVJfSU1BR0V9IiBcCiAgICAgICAgLS1pbWFnZS1zY3JpcHRzLXVybCAiJHtQQVJBTVNfSU1BR0VfU0NSSVBUU19VUkx9IiBcCiAgICAgICAgLS1hcy1kb2NrZXJmaWxlICIke1MySV9DT05UQUlORVJGSUxFX1BBVEh9IiBcCiAgICAgICAgLS1lbnZpcm9ubWVudC1maWxlICIke1MySV9FTlZJUk9OTUVOVF9GSUxFfSIKCnBoYXNlICJJbnNwZWN0aW5nIHRoZSBDb250YWluZXJmaWxlIGdlbmVyYXRlZCBhdCAnJHtTMklfQ09OVEFJTkVSRklMRV9QQVRIfSciCltbICEgLWYgIiR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH0iIF1dICYmCiAgICBmYWlsICJHZW5lcmF0ZWQgQ29udGFpbmVyZmlsZSBpcyBub3QgZm91bmQhIgoKc2V0ICt4CnBoYXNlICJHZW5lcmF0ZWQgQ29udGFpbmVyZmlsZSBwYXlsb2FkIgplY2hvIC1lbiAiPj4+ICR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH1cbiQoY2F0ICR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH0pXG48PDwgRU9GXG4iCg==" |base64 -d >s2i-generate.sh + chmod +x s2i-*.sh + volumeMounts: + - name: scripts-dir + mountPath: /scripts + + - name: s2i-generate + image: quay.io/openshift-pipeline/s2i:nightly + workingDir: $(workspaces.source.path) + env: + - name: S2I_BUILDER_IMAGE + value: registry.access.redhat.com/ubi8/python-39:latest + command: + - /scripts/s2i-generate.sh + args: + - "$(params.ENV_VARS[*])" + securityContext: + runAsUser: 0 + volumeMounts: + - name: scripts-dir + mountPath: /scripts + - name: s2i-generate-dir + mountPath: /s2i-generate + + - name: s2i-build + image: registry.access.redhat.com/ubi8/buildah:latest + workingDir: /s2i-generate + command: + - /scripts/s2i-build.sh + securityContext: + privileged: true + volumeMounts: + - name: scripts-dir + mountPath: /scripts + - name: s2i-generate-dir + mountPath: /s2i-generate + + volumes: + - name: scripts-dir + emptyDir: {} + - name: s2i-generate-dir + emptyDir: {} diff --git a/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-ruby/v0.1.0/README.md b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-ruby/v0.1.0/README.md new file mode 100644 index 00000000..b86765b3 --- /dev/null +++ b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-ruby/v0.1.0/README.md @@ -0,0 +1,83 @@ +Source-to-Image Tekton Tasks (`s2i`) +------------------------------------ + +# Abstract + +Describes the Tekton Tasks supporting Source-to-Image for various ecosystems. + +# `s2i` Builder Images + +This section we explain each language ecosystem comes with a predefined set of builder images, supported by Red Hat. + +The `s2i` Task helps in building reproducible container images from source code i.e. task for supporting s2i functionality. + +The s2i Task has been customized with builder images specific to various languages and have been named appropriately as follows: + +| Task Name | Builder Image Used | +| ---------- | ---------------------------------------------------------------------- | +| s2i-python | http://registry.access.redhat.com/ubi8/python-39:latest | +| s2i-go | http://registry.access.redhat.com/ubi8/go-toolset:1.19.10-3 | +| s2i-java | http://registry.access.redhat.com/ubi8/openjdk-11:latest | +| s2i-dotnet | http://registry.access.redhat.com/ubi8/dotnet-60:6.0-37.20230802191230 | +| s2i-php | http://registry.access.redhat.com/ubi9/php-81:1-29 | +| s2i-nodejs | http://registry.access.redhat.com/ubi8/nodejs-18:latest | +| s2i-perl | http://registry.access.redhat.com/ubi9/perl-532:1-91 | +| s2i-ruby | http://registry.access.redhat.com/ubi9/ruby-31:1-50 | + +In case, the above builder images associated with the languages aren’t satisfactory for your source code, you can change it using appropriate parameter. + +# Usage + +Please, consider the usage example below: + +```yaml +--- +apiVersion: tekton.dev/v1beta1 +kind: TaskRun +metadata: {} +spec: + taskRef: + name: s2i-python + params: + - name: IMAGE + value: registry.registry.svc.cluster.local:32222/task-containers/task-s2i-python:latest +``` + +In case the Container Registry requires authentication, please consider the [Tekton Pipelines documentation][tektonPipelineAuth]. In a nutshell, you need to create a Kubernetes Secret describing the following attributes: + +```bash +kubectl create secret docker-registry imagestreams \ + --docker-server="image-registry.openshift-image-registry.svc:5000" \ + --docker-username="${REGISTRY_USERNAME}" \ + --docker-password="${REGISTRY_TOKEN}" +``` + +Then make sure the Secret is linked with the Service-Account running the `TaskRun`/`PipelineRun`. + +## Workspaces + +All of the s2i tasks use the `source` workspace which is meant to contain the Application source code, which acts as the build context for S2I workflow. + + +## Params + +| Param | Type | Default | Description | +| ----------------- | ------ | ------------------------ | ------------------------------------------------------------------------- | +| IMAGE | string | (required) | Fully qualified container image name to be built by s2i | +| IMAGE_SCRIPTS_URL | string | image:///usr/libexec/s2i | URL containing the default assemble and run scripts for the builder image | +| ENV_VARS | array | [] | Array containing string of Environment Variables as "KEY=VALUE” | +| SUBDIRECTORY | string | . | Relative subdirectory to the source Workspace for the build-context. | +| STORAGE_DRIVER | string | overlay | Set buildah storage driver to reflect the currrent cluster node's | +| settings. | +| BUILD_EXTRA_ARGS | string | | Extra parameters passed for the build command when building images. | +| PUSH_EXTRA_ARGS | string | | Extra parameters passed for the push command when pushing images. | +| SKIP_PUSH | string | false | Skip pushing the image to the container registry. | +| TLS_VERIFY | string | true | Sets the TLS verification flag, true is recommended. | +| VERBOSE | string | false | Turns on verbose logging, all commands executed will be printed out. | + +## Results + +| Result | Description | +| ------------ | ------------------------------- | +| IMAGE_URL | Fully qualified image name. | +| IMAGE_DIGEST | Digest of the image just built. | diff --git a/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-ruby/v0.1.0/task-s2i-ruby.yaml b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-ruby/v0.1.0/task-s2i-ruby.yaml new file mode 100644 index 00000000..a6e584a5 --- /dev/null +++ b/experimental/tmp/task-containers-0.1.0/release/tasks/task-s2i-ruby/v0.1.0/task-s2i-ruby.yaml @@ -0,0 +1,168 @@ +--- +# Source: task-containers/templates/task-s2i-ruby.yaml +apiVersion: tekton.dev/v1beta1 +kind: Task +metadata: + name: s2i-ruby + labels: + app.kubernetes.io/version: 0.1.0 + annotations: + tekton.dev/categories: containers + tekton.dev/pipelines.minVersion: 0.38.0 + tekton.dev/tags: containers +spec: + description: | + Builds the source code using the s2i's Ruby builder-image + "registry.access.redhat.com/ubi9/ruby-31:1-50". + + + workspaces: + - name: source + optional: false + description: | + Application source code, the build context for S2I workflow. + + params: + - name: IMAGE + type: string + description: | + Fully qualified container image name to be built by s2i. + - name: IMAGE_SCRIPTS_URL + type: string + default: image:///usr/libexec/s2i + description: | + Specify a URL containing the default assemble and run scripts for the builder image + - name: ENV_VARS + type: array + default: [] + description: | + Array containing string of Environment Variables as "KEY=VALUE" + - name: SUBDIRECTORY + type: string + default: "." + description: | + Relative subdirectory to the `source` Workspace for the build-context. + - name: STORAGE_DRIVER + type: string + default: overlay + description: | + Set buildah storage driver to reflect the currrent cluster node's + settings. + - name: BUILD_EXTRA_ARGS + type: string + default: "" + description: | + Extra parameters passed for the build command when building images. + - name: PUSH_EXTRA_ARGS + type: string + default: "" + description: | + Extra parameters passed for the push command when pushing images. + - name: SKIP_PUSH + default: "false" + description: | + Skip pushing the image to the container registry. + - name: TLS_VERIFY + type: string + default: "true" + description: | + Sets the TLS verification flag, `true` is recommended. + - name: VERBOSE + type: string + default: "false" + description: | + Turns on verbose logging, all commands executed will be printed out. + + results: + - name: IMAGE_URL + description: | + Fully qualified image name. + - name: IMAGE_DIGEST + description: | + Digest of the image just built. + + stepTemplate: + env: + + - name: PARAMS_IMAGE + value: "$(params.IMAGE)" + - name: PARAMS_IMAGE_SCRIPTS_URL + value: "$(params.IMAGE_SCRIPTS_URL)" + - name: PARAMS_SUBDIRECTORY + value: "$(params.SUBDIRECTORY)" + - name: PARAMS_STORAGE_DRIVER + value: "$(params.STORAGE_DRIVER)" + - name: PARAMS_BUILD_EXTRA_ARGS + value: "$(params.BUILD_EXTRA_ARGS)" + - name: PARAMS_PUSH_EXTRA_ARGS + value: "$(params.PUSH_EXTRA_ARGS)" + - name: PARAMS_SKIP_PUSH + value: "$(params.SKIP_PUSH)" + - name: PARAMS_TLS_VERIFY + value: "$(params.TLS_VERIFY)" + - name: PARAMS_VERBOSE + value: "$(params.VERBOSE)" + - name: WORKSPACES_SOURCE_BOUND + value: "$(workspaces.source.bound)" + - name: WORKSPACES_SOURCE_PATH + value: "$(workspaces.source.path)" + - name: RESULTS_IMAGE_URL_PATH + value: "$(results.IMAGE_URL.path)" + - name: RESULTS_IMAGE_DIGEST_PATH + value: "$(results.IMAGE_DIGEST.path)" + + steps: + - name: load-scripts + image: docker.io/library/bash:latest + workingDir: /scripts + script: | + set -e + printf '%s' "IyEvdXNyL2Jpbi9lbnYgYmFzaAojCiMgV3JhcHBlciBhcm91bmQgImJ1aWxkYWggYnVkIiB0byBidWlsZCBhbmQgcHVzaCBhIGNvbnRhaW5lciBpbWFnZSBiYXNlZCBvbiBhIENvbnRhaW5lcmZpbGUuCiMKCnNob3B0IC1zIGluaGVyaXRfZXJyZXhpdApzZXQgLWV1IC1vIHBpcGVmYWlsCgpzb3VyY2UgIiQoZGlybmFtZSAke0JBU0hfU09VUkNFWzBdfSkvY29tbW9uLnNoIgpzb3VyY2UgIiQoZGlybmFtZSAke0JBU0hfU09VUkNFWzBdfSkvYnVpbGRhaC1jb21tb24uc2giCgpmdW5jdGlvbiBfYnVpbGRhaCgpIHsKICAgIGJ1aWxkYWggXAogICAgICAgIC0tc3RvcmFnZS1kcml2ZXI9IiR7UEFSQU1TX1NUT1JBR0VfRFJJVkVSfSIgXAogICAgICAgIC0tdGxzLXZlcmlmeT0iJHtQQVJBTVNfVExTX1ZFUklGWX0iIFwKICAgICAgICAkeyp9Cn0KCiMKIyBQcmVwYXJlCiMKCiMgbWFraW5nIHN1cmUgdGhlIHJlcXVpcmVkIHdvcmtzcGFjZSAic291cmNlIiBpcyBib3VuZGVkLCB3aGljaCBtZWFucyBpdHMgdm9sdW1lIGlzIGN1cnJlbnRseSBtb3VudGVkCiMgYW5kIHJlYWR5IHRvIHVzZQpwaGFzZSAiSW5z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AgICAgICBmYWlsICInJHt2fScgZW52aXJvbm1lbnQgdmFyaWFibGUgaXMgbm90IHNldCEiCiAgICBkb25lCgogICAgcmV0dXJuIDAKfQo=" |base64 -d >common.sh + chmod +x buildah-*.sh + printf '%s' "IyEvdXNyL2Jpbi9lbnYgYmFzaAoKIyB0ZWt0b24ncyBob21lIGRpcmVjdG9yeQpkZWNsYXJlIC1yeCBURUtUT05fSE9NRT0iJHtURUtUT05fSE9NRTotL3Rla3Rvbi9ob21lfSIKCiMKIyBGdW5jdGlvbnMKIwoKZnVuY3Rpb24gZmFpbCgpIHsKICAgIGVjaG8gIkVSUk9SOiAkeyp9IiAyPiYxCiAgICBleGl0IDEKfQoKZnVuY3Rpb24gcGhhc2UoKSB7CiAgICBlY2hvICItLS0+IFBoYXNlOiAkeyp9Li4uIgp9CgojIGFzc2VydCBsb2NhbCB2YXJpYWJsZXMgYXJlIGV4cG9yZXRlZCBvbiB0aGUgZW52aXJvbm1lbnQKZnVuY3Rpb24gZXhwb3J0ZWRfb3JfZmFpbCgpIHsKICAgIGRlY2xhcmUgLWEgX3JlcXVpcmVkX3ZhcnM9IiR7QH0iCgogICAgZm9yIHYgaW4gJHtfcmVxdWlyZWRfdmFyc1tAXX07IGRvCiAgICAgICAgW1sgLXogIiR7IXZ9IiBdXSAmJgogICAgICAgICAgICBmYWlsICInJHt2fScgZW52aXJvbm1lbnQgdmFyaWFibGUgaXMgbm90IHNldCEiCiAgICBkb25lCgogICAgcmV0dXJuIDAKfQo=" |base64 -d >common.sh + printf '%s' "IyEvdXNyL2Jpbi9lbnYgYmFzaAojCiMgVXNlcyB0aGUgQ29udGlhbmVyZmlsZSBnZW5lcmF0ZWQgYnkgczJpIHRvIGFzc2VtYmxlIGEgbmV3IGNvbnRhaW5lciBpbWFnZSB1c2luZyBidWlsZGFoLgojCgpzaG9wdCAtcyBpbmhlcml0X2VycmV4aXQKc2V0IC1ldSAtbyBwaXBlZmFpbAoKZGVjbGFyZSAtciBjdXJfZGly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iAgICBidWlsZCAiJHtQQVJBTVNfU1VCRElSRUNUT1JZfSIgIiR7UzJJX0JVSUxERVJfSU1BR0V9IiBcCiAgICAgICAgLS1pbWFnZS1zY3JpcHRzLXVybCAiJHtQQVJBTVNfSU1BR0VfU0NSSVBUU19VUkx9IiBcCiAgICAgICAgLS1hcy1kb2NrZXJmaWxlICIke1MySV9DT05UQUlORVJGSUxFX1BBVEh9IiBcCiAgICAgICAgLS1lbnZpcm9ubWVudC1maWxlICIke1MySV9FTlZJUk9OTUVOVF9GSUxFfSIKCnBoYXNlICJJbnNwZWN0aW5nIHRoZSBDb250YWluZXJmaWxlIGdlbmVyYXRlZCBhdCAnJHtTMklfQ09OVEFJTkVSRklMRV9QQVRIfSciCltbICEgLWYgIiR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH0iIF1dICYmCiAgICBmYWlsICJHZW5lcmF0ZWQgQ29udGFpbmVyZmlsZSBpcyBub3QgZm91bmQhIgoKc2V0ICt4CnBoYXNlICJHZW5lcmF0ZWQgQ29udGFpbmVyZmlsZSBwYXlsb2FkIgplY2hvIC1lbiAiPj4+ICR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH1cbiQoY2F0ICR7UzJJX0NPTlRBSU5FUkZJTEVfUEFUSH0pXG48PDwgRU9GXG4iCg==" |base64 -d >s2i-generate.sh + chmod +x s2i-*.sh + volumeMounts: + - name: scripts-dir + mountPath: /scripts + + - name: s2i-generate + image: quay.io/openshift-pipeline/s2i:nightly + workingDir: $(workspaces.source.path) + env: + - name: S2I_BUILDER_IMAGE + value: registry.access.redhat.com/ubi9/ruby-31:1-50 + command: + - /scripts/s2i-generate.sh + args: + - "$(params.ENV_VARS[*])" + securityContext: + runAsUser: 0 + volumeMounts: + - name: scripts-dir + mountPath: /scripts + - name: s2i-generate-dir + mountPath: /s2i-generate + + - name: s2i-build + image: registry.access.redhat.com/ubi8/buildah:latest + workingDir: /s2i-generate + command: + - /scripts/s2i-build.sh + securityContext: + privileged: true + volumeMounts: + - name: scripts-dir + mountPath: /scripts + - name: s2i-generate-dir + mountPath: /s2i-generate + + volumes: + - name: scripts-dir + emptyDir: {} + - name: s2i-generate-dir + emptyDir: {} diff --git a/experimental/tmp/task-containers-0.1.0/release/tasks/task-skopeo-copy/v0.1.0/README.md b/experimental/tmp/task-containers-0.1.0/release/tasks/task-skopeo-copy/v0.1.0/README.md new file mode 100644 index 00000000..ee6fa59d --- /dev/null +++ b/experimental/tmp/task-containers-0.1.0/release/tasks/task-skopeo-copy/v0.1.0/README.md @@ -0,0 +1,59 @@ +Containers Tekton Tasks +----------------------- + +# Abstract + +Describes the Tekton Tasks supporting Skopeo-Copy + +# `skopeo-copy` Tekton Task + +The `skopeo-copy` Task is meant to replicate a container image from the `SOURCE` registry to the `DESTINATION` using [Skopeo][containersSkopeo], the Task results contain the SHA256 digests. + +# Usage + +Please, consider the usage example below: + +```yaml +--- +apiVersion: tekton.dev/v1beta1 +kind: TaskRun +metadata: {} +spec: + taskRef: + name: skopeo-copy + params: + - name: SOURCE + value: docker://docker.io/busybox:latest + - name: DESTINATION + value: docker://image-registry.openshift-image-registry.svc:5000/task-containers/busybox:latest +``` + +In case the Container Registry requires authentication, please consider the [Tekton Pipelines documentation][tektonPipelineAuth]. In a nutshell, you need to create a Kubernetes Secret describing the following attributes: + +```bash +kubectl create secret docker-registry imagestreams \ + --docker-server="image-registry.openshift-image-registry.svc:5000" \ + --docker-username="${REGISTRY_USERNAME}" \ + --docker-password="${REGISTRY_TOKEN}" +``` + +Then make sure the Secret is linked with the Service-Account running the `TaskRun`/`PipelineRun`. + +## Params + +| Param | Type | Default | Description | +| :------------ | :------------------------: | :--------------------------- | :------------------------- | +| `SOURCE` | `string` | (required) | Fully qualified source container image name, including tag, to be copied into `DESTINATION` param. | +| `DESTINATION` | `string` | (required) | Fully qualified destination container image name, including tag. | +| `TLS_VERIFY` | `string` | `true` | Sets the TLS verification flags, `true` is recommended. | +| `VERBOSE` | `string` | `false` | Shows a more verbose (debug) output. | + +## Results + +| Result | Description | +| :------------ | :------------------------- | +| `SOURCE_DIGEST` | Source image SHA256 digest. | +| `DESTINATION_DIGEST` | Destination image SHA256 digest. | + +[tektonPipelineAuth]: https://tekton.dev/docs/pipelines/auth/#configuring-docker-authentication-for-docker +[containersSkopeo]: https://github.com/containers/skopeo diff --git a/experimental/tmp/task-containers-0.1.0/release/tasks/task-skopeo-copy/v0.1.0/task-skopeo-copy.yaml b/experimental/tmp/task-containers-0.1.0/release/tasks/task-skopeo-copy/v0.1.0/task-skopeo-copy.yaml new file mode 100644 index 00000000..bbc2b257 --- /dev/null +++ b/experimental/tmp/task-containers-0.1.0/release/tasks/task-skopeo-copy/v0.1.0/task-skopeo-copy.yaml @@ -0,0 +1,99 @@ +--- +# Source: task-containers/templates/task-skopeo-copy.yaml +apiVersion: tekton.dev/v1beta1 +kind: Task +metadata: + name: skopeo-copy + labels: + app.kubernetes.io/version: 0.1.0 + annotations: + tekton.dev/categories: containers + tekton.dev/pipelines.minVersion: 0.38.0 + tekton.dev/tags: containers +spec: + description: | + Uses `skopeo copy` to replicate the `SOURCE` (param) container image into + `DESTINATION`. After copying the source and destination images SHA256 digest + is stored as results. + + params: + - name: SOURCE + type: string + description: | + Fully qualified source container image name, including tag, to be copied + into `DESTINATION` param. + - name: DESTINATION + type: string + description: | + Fully qualified destination container image name, including tag. + - name: TLS_VERIFY + type: string + default: "true" + description: | + Sets the TLS verification flags, `true` is recommended. + - name: VERBOSE + type: string + default: "false" + description: | + Shows a more verbose (debug) output. + + results: + - name: SOURCE_DIGEST + type: string + description: | + Source image SHA256 digest. + - name: DESTINATION_DIGEST + type: string + description: | + Destination image SHA256 digest. + + volumes: + - name: scripts-dir + emptyDir: {} + + stepTemplate: + env: + + - name: PARAMS_SOURCE + value: "$(params.SOURCE)" + - name: PARAMS_DESTINATION + value: "$(params.DESTINATION)" + - name: PARAMS_TLS_VERIFY + value: "$(params.TLS_VERIFY)" + - name: PARAMS_VERBOSE + value: "$(params.VERBOSE)" + - name: RESULTS_SOURCE_DIGEST_PATH + value: "$(results.SOURCE_DIGEST.path)" + - name: RESULTS_DESTINATION_DIGEST_PATH + value: "$(results.DESTINATION_DIGEST.path)" + + steps: + - name: load-scripts + image: docker.io/library/bash:latest + workingDir: /scripts + script: | + set -e + printf '%s' "IyEvdXNyL2Jpbi9lbnYgYmFzaAoKIyB0ZWt0b24ncyBob21lIGRpcmVjdG9yeQpkZWNsYXJlIC1yeCBURUtUT05fSE9NRT0iJHtURUtUT05fSE9NRTotL3Rla3Rvbi9ob21lfSIKCiMKIyBGdW5jdGlvbnMKIwoKZnVuY3Rpb24gZmFpbCgpIHsKICAgIGVjaG8gIkVSUk9SOiAkeyp9IiAyPiYxCiAgICBleGl0IDEKfQoKZnVuY3Rpb24gcGhhc2UoKSB7CiAgICBlY2hvICItLS0+IFBoYXNlOiAkeyp9Li4uIgp9CgojIGFzc2VydCBsb2NhbCB2YXJpYWJsZXMgYXJlIGV4cG9yZXRlZCBvbiB0aGUgZW52aXJvbm1lbnQKZnVuY3Rpb24gZXhwb3J0ZWRfb3JfZmFpbCgpIHsKICAgIGRlY2xhcmUgLWEgX3JlcXVpcmVkX3ZhcnM9IiR7QH0iCgogICAgZm9yIHYgaW4gJHtfcmVxdWlyZWRfdmFyc1tAXX07IGRvCiAgICAgICAgW1sgLXogIiR7IXZ9IiBdXSAmJgogICAgICAgICAgICBmYWlsICInJHt2fScgZW52aXJvbm1lbnQgdmFyaWFibGUgaXMgbm90IHNldCEiCiAgICBkb25lCgogICAgcmV0dXJuIDAKfQo=" |base64 -d >common.sh + printf '%s' "IyEvdXNyL2Jpbi9lbnYgYmFzaAoKZGVjbGFyZSAtcnggUEFSQU1TX1NPVVJDRT0iJHtQQVJBTVNfU09VUkNFOi19IgpkZWNsYXJlIC1yeCBQQVJBTVNfREVTVElOQVRJT049IiR7UEFSQU1TX0RFU1RJTkFUSU9OOi19IgpkZWNsYXJlIC1yeCBQQVJBTVNfVExTX1ZFUklGWT0iJH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DRX0nIHNvdXJjZSBpbWFnZSBkaWdlc3QiCnNvdXJjZV9kaWdlc3Q9IiQoc2tvcGVvX2luc3BlY3QgJHtQQVJBTVNfU09VUkNFfSkiCnBoYXNlICJTb3VyY2UgaW1hZ2UgZGlnZXN0ICcke3NvdXJjZV9kaWdlc3R9JyIKCnBoYXNlICJFeHRyYWN0aW5nICcke1BBUkFNU19ERVNUSU5BVElPTn0nIGRlc3RpbmF0aW9uIGltYWdlIGRpZ2VzdCIKZGVzdGluYXRpb25fZGlnZXN0PSIkKHNrb3Blb19pbnNwZWN0ICR7UEFSQU1TX0RFU1RJTkFUSU9OfSkiCnBoYXNlICJEZXN0aW5hdGlvbiBpbWFnZSBkaWdlc3QgJyR7ZGVzdGluYXRpb25fZGlnZXN0fSciCgpwcmludGYgIiVzIiAke3NvdXJjZV9kaWdlc3R9ID4ke1JFU1VMVFNfU09VUkNFX0RJR0VTVF9QQVRIfQpwcmludGYgIiVzIiAke2Rlc3RpbmF0aW9uX2RpZ2VzdH0gPiR7UkVTVUxUU19ERVNUSU5BVElPTl9ESUdFU1RfUEFUSH0K" |base64 -d >skopeo-results.sh + chmod +x skopeo-*.sh + volumeMounts: + - name: scripts-dir + mountPath: /scripts + + - name: skopeo-copy + image: quay.io/skopeo/stable:latest + command: + - /scripts/skopeo-copy.sh + volumeMounts: + - name: scripts-dir + mountPath: /scripts + + - name: skopeo-results + image: quay.io/skopeo/stable:latest + command: + - /scripts/skopeo-results.sh + volumeMounts: + - name: scripts-dir + mountPath: /scripts