Sample Kubernetes serviceaccount including GitHub (remember to use Personal Auth Token, not Username/Password if you've got 2FA enabled) and Docker Hub. Used for a kpack demonstration.
--- | |
apiVersion: v1 | |
kind: Secret | |
metadata: | |
name: dockerhub | |
annotations: | |
build.pivotal.io/docker: index.docker.io | |
type: kubernetes.io/basic-auth | |
stringData: | |
username: <username/email> | |
password: <password> | |
--- | |
apiVersion: v1 | |
kind: Secret | |
metadata: | |
name: github | |
annotations: | |
build.pivotal.io/git: https://github.com | |
type: kubernetes.io/basic-auth | |
stringData: | |
username: <github personal token> | |
password: "" | |
--- | |
apiVersion: v1 | |
kind: ServiceAccount | |
metadata: | |
name: service-account | |
secrets: | |
- name: dockerhub | |
- name: github |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment