1
0
mirror of https://github.com/tektoncd/catalog.git synced 2024-11-25 06:17:50 +00:00
catalog/task/gcs-upload/0.1
vinamra28 32f2913fd2 Fix Catlin error by adding Digest to the Images
- Previously catalog's task has some images that are not
  tagged properly,this patch fixes these images by adding
  the digest
- Soon once Catlin is added to the CI it will throw error
  for those images which don't have proper tags

co-authored by:- @PuneetPunamiya

Signed-off-by: vinamra28 <vinjain@redhat.com>
2020-10-26 09:03:20 +00:00
..
samples Modifies directory names based on the proposal 2020-07-14 19:01:58 +01:00
gcs-upload.yaml Fix Catlin error by adding Digest to the Images 2020-10-26 09:03:20 +00:00
README.md This patch splits gcs-upload task from the gcs directory 2020-07-13 13:41:58 +01:00

Google Cloud Storage Tasks

These Tasks are for copying to and from GCS buckets from Pipelines.

These Tasks do a similar job to the GCS PipelineResource and are intended as its replacement. This is part of our plan to offer replacement Tasks for Pipeline Resources as well as document those replacements.

gcs-upload

A Task that uploads files or directories from a Workspace to a GCS bucket.

Workspaces

  • credentials: A workspace that contains a service account key as a JSON file. This workspace should be populated from a Secret in your TaskRuns and PipelineRuns.
  • source: A workspace where files will be uploaded from.

Parameters

  • path: The path to files or directories relative to the source workspace that you'd like to upload. (required)
  • location: The address (including "gs://") where you'd like to upload files to. (required)
  • serviceAccountPath: The path to the service account credential file in your credentials workspace. (default: "service_account.json")

Usage

gcs-upload

This TaskRun uses the gcs-upload Task to upload a file from a ConfigMap.

kind: ConfigMap
apiVersion: v1
metadata:
  name: test-input-data
data:
  test_file.txt: "Hello, world!"
---
apiVersion: tekton.dev/v1beta1
kind: TaskRun
metadata:
  name: upload-configmap-file-to-gcs
spec:
  taskRef:
    name: gcs-upload
  workspaces:
  - name: credentials
    secret:
      secretName: my-gcs-credentials
      defaultMode: 0400
  - name: source
    configMap:
      name: test-input-data