Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add docs for secrets based on existing credentials #430

Merged

Conversation

concaf
Copy link
Contributor

@concaf concaf commented Apr 25, 2022

The current docs on "Authenticating to an OCI Registry" cover creating a
secret by providing credentials on the command line but do not cover
creating a secret based on existing credentials; this commit adds that.

Fixes #314

CC: @priyawadhwa

@tekton-robot tekton-robot added the size/S Denotes a PR that changes 10-29 lines, ignoring generated files. label Apr 25, 2022
Set the namespace and name of the Kubernetes service account:

```shell
export NAMESPACE=<your namespace>
export SERVICE_ACCOUNT_NAME=<service account name>
```

### Create a Secret based on existing credentials

If you already ran `docker login`, you can copy the credentials into Kubernetes:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we add a step here where users confirm that the ~/.docker/config.json file is in this format?

{
  "auths": {
    "https://index.docker.io/v1/": {
      "auth": "redacted"
    }
}

on mac the dockerconfig uses keychain so it usually isn't in this format

Copy link
Contributor Author

@concaf concaf Apr 26, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@priyawadhwa makes sense! Updated, PTAL 🙃

The current docs on "Authenticating to an OCI Registry" cover creating a
secret by providing credentials on the command line but do not cover
creating a secret based on existing credentials; this commit adds that.
@concaf concaf force-pushed the concaf/docs/fix-authentication-oci branch from f5c5e7e to 3d42d31 Compare April 26, 2022 08:24
@tekton-robot tekton-robot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Apr 26, 2022
@tekton-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: priyawadhwa

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@tekton-robot tekton-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Apr 28, 2022
@priyawadhwa
Copy link
Contributor

Thanks @concaf !

@priyawadhwa
Copy link
Contributor

/lgtm

@tekton-robot tekton-robot added the lgtm Indicates that a PR is ready to be merged. label Apr 28, 2022
@tekton-robot tekton-robot merged commit 2065bc6 into tektoncd:main Apr 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update Chains authentication doc with auth for DockerHub
3 participants