Sign inSign up

sbx/github-cli:latest

Multi-platform
Manifest digest

sha256:eb3798d4992e7654adb2ad3ef43eafc31b5fd182966112634dd86980b8e90cb0

Last pushed

1 day by dhibot

Type

Sandbox Kit

Manifest digest

sha256:eb3798d4992e7654adb2ad3ef43eafc31b5fd182966112634dd86980b8e90cb0

yaml
schemaVersion: "3"
displayName: GitHub CLI
author: Docker, Inc. https://docker.com
description: GitHub CLI overlay with scoped GitHub access and proxy-managed authentication.
sourceUrl: https://github.com/cli/cli
version: 2.104.0
licenses:
    - MIT
kind: mixin
provides:
    - [email protected]
capabilities:
    - type: com.docker.sandbox/network-policy@2
      config:
        runtime:
            allow:
                - github.com
                - hosts:
                    - api.github.com
                  methods:
                    - GET
                    - HEAD
                    - POST
                    - PATCH
                    - PUT
                    - DELETE
                - hosts:
                    - uploads.github.com
                  methods:
                    - POST
                    - PUT
            deny:
                - hosts:
                    - api.github.com
                  methods:
                    - DELETE
                  paths:
                    - /repos/**
    - type: com.docker.sandbox/credential@1
      optional: true
      config:
        apiKey:
            inject:
                - domain: api.github.com
                  format: Bearer %s
                  header: Authorization
                - domain: uploads.github.com
                  format: Bearer %s
                  header: Authorization
                - domain: github.com
                  format: Bearer %s
                  header: Authorization
            name: GH_TOKEN
            proxyManaged: true
        phase:
            - runtime
        service: github
      description: GitHub API access for gh
    - type: com.docker.sandbox/agent-context@1
      optional: true
      config:
        content: |
            # GitHub CLI

            `gh` is on PATH at `/usr/local/bin/gh`.

            - Authentication is proxy-managed: `GH_TOKEN` is set to a sentinel and the
              real credential is injected on requests to github.com, api.github.com,
              and uploads.github.com. Never print or copy the token; it is not the
              real value anyway.
            - Do not run `gh auth login` — authentication already works.
            - Prefer `gh` over raw git for GitHub operations: `gh pr create`,
              `gh issue list`, `gh run watch`, `gh api` for anything without a
              dedicated subcommand.
    - type: com.docker.sandbox/agent-context@2
      optional: true
      config:
        content: |
            # GitHub CLI

            `gh` is on PATH at `/usr/local/bin/gh`.

            - Authentication is proxy-managed: `GH_TOKEN` is set to a sentinel and the
              real credential is injected on requests to github.com, api.github.com,
              and uploads.github.com. Never print or copy the token; it is not the
              real value anyway.
            - Do not run `gh auth login` — authentication already works.
            - Prefer `gh` over raw git for GitHub operations: `gh pr create`,
              `gh issue list`, `gh run watch`, `gh api` for anything without a
              dedicated subcommand.
args:
    version:
        required: true
        description: GitHub CLI release carried by the overlay
        pattern: ^2\.[0-9]+\.[0-9]+$
        buildArg: GH_VERSION