{
  "name": "publish-artifact",
  "title": "Publish a build artifact",
  "category": "CI/CD",
  "tags": [
    "ci-cd",
    "curl"
  ],
  "version": "1.0.1",
  "date": "2026-08-02",
  "notes": "Move curlimages/curl from 8.11.1 to 8.21.0. Fixable CRITICAL/HIGH drops from 26 to 1.",
  "latest": true,
  "installable": true,
  "url": "https://catalog.dagweave.com/api/v1/items/publish-artifact/1.0.1.json",
  "templateUrl": "https://catalog.dagweave.com/api/v1/items/publish-artifact/1.0.1/template.yaml",
  "entrypoint": "publish",
  "parameters": [
    {
      "name": "file-path",
      "title": "File path",
      "description": "Path to the file to upload (in the run's filesystem / mounted volume).",
      "type": "string",
      "required": true,
      "example": "/workspace/dist/app-1.2.3.tgz"
    },
    {
      "name": "registry-url",
      "title": "Registry URL",
      "description": "Destination URL to PUT the artifact to.",
      "type": "string",
      "required": true,
      "example": "https://artifacts.internal/repo/app-1.2.3.tgz"
    },
    {
      "name": "credentials-secret-key",
      "title": "Credentials secret key",
      "description": "Key within the Secret that holds the credentials.",
      "type": "string",
      "required": false,
      "default": "credentials"
    },
    {
      "name": "credentials-secret-name",
      "title": "Credentials secret name",
      "description": "Name of the Kubernetes Secret holding the registry credentials, formatted as \"user:password\".",
      "type": "string",
      "required": false,
      "default": "artifact-registry-credentials"
    }
  ],
  "images": [
    {
      "ref": "curlimages/curl@sha256:3fb7e13e5d179a845c97d78204f3f1064d1907037f26a3ebf91710571151fd93",
      "repository": "curlimages/curl",
      "tag": "8.23.0",
      "digest": "sha256:3fb7e13e5d179a845c97d78204f3f1064d1907037f26a3ebf91710571151fd93"
    }
  ],
  "install": {
    "kubectl": "kubectl apply -n argo -f https://catalog.dagweave.com/api/v1/items/publish-artifact/1.0.1/template.yaml",
    "argo": "argo template create -n argo https://catalog.dagweave.com/api/v1/items/publish-artifact/1.0.1/template.yaml"
  },
  "template": "apiVersion: argoproj.io/v1alpha1\nkind: WorkflowTemplate\nmetadata:\n  name: publish-artifact\n  labels:\n    dagweave.io/catalog-item: publish-artifact\n  annotations:\n    # The catalog semver this manifest was authored at. The dagweave app records\n    # (catalog-item-id, semver) -\u003e content-hash -\u003e base-vN when it mints the tenant\n    # cluster name via ResolveOrMint. Keep in sync with metadata.yaml `version`.\n    dagweave.io/catalog-version: \"1.0.1\"\n    dagweave.io/catalog-category: \"CI/CD\"\nspec:\n  entrypoint: publish\n  templates:\n    - name: publish\n      inputs:\n        parameters:\n          # Path to the file to upload (in the run's filesystem / mounted volume).\n          - name: file-path\n          # Destination URL to PUT the artifact to.\n          - name: registry-url\n          # Name of the Kubernetes Secret holding the registry credentials, formatted\n          # as \"user:password\" for HTTP basic auth. Defaults let a user leave them\n          # blank in the Inspector.\n          - name: credentials-secret-name\n            default: artifact-registry-credentials\n          - name: credentials-secret-key\n            default: credentials\n      container:\n        # Pinned by digest per the catalog convention: an image rebuild can never\n        # silently change the behaviour of an already-released item version.\n        # curlimages/curl:8.23.0\n        image: curlimages/curl@sha256:3fb7e13e5d179a845c97d78204f3f1064d1907037f26a3ebf91710571151fd93\n        command: [sh, -c]\n        # The file path, URL and credentials are passed as env vars (below), never\n        # interpolated from Argo into the shell, so values with quotes or shell\n        # metacharacters are safe. -sSf makes a non-2xx response fail the step.\n        args:\n          - |\n            set -eu\n            curl -sSf -u \"$CREDENTIALS\" --upload-file \"$FILE_PATH\" \"$REGISTRY_URL\"\n        env:\n          - name: FILE_PATH\n            value: \"{{inputs.parameters.file-path}}\"\n          - name: REGISTRY_URL\n            value: \"{{inputs.parameters.registry-url}}\"\n          - name: CREDENTIALS\n            valueFrom:\n              secretKeyRef:\n                name: \"{{inputs.parameters.credentials-secret-name}}\"\n                key: \"{{inputs.parameters.credentials-secret-key}}\"\n",
  "templateSha256": "a1e32bb1582ba652c0815fcfc51de4d73ed672acb4837833001120ef6d44aee3",
  "source": "https://github.com/dagweave/catalog/tree/67458f74dbbf913b03177f3cefc69424be85eb1d/catalog/publish-artifact",
  "catalogSha": "67458f74dbbf913b03177f3cefc69424be85eb1d"
}
