Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( DockerBase = flag.String("docker-url", "https://docker.myorg.net", "when there is only one (legacy option)") DockerURLs = flag.String("docker-urls", "https://harbor.myorg.net,https://ghcr.myorg.net", "csv of docker server base URLs") DockerScheme = flag.String("docker-auth-scheme", "https", "(only for testing)") GHPHost = flag.String("ghp-hosts", "ghp.myorg.net", "CSV of github packages domains") )
View Source
var Debug *bool
Debug flag reference (set by main package)
View Source
var Handler func(http.ResponseWriter, *http.Request)
Handler function (set by main package)
View Source
var LogRoundtrip func(*http.Response)
LogRoundtrip function (set by main package)
Functions ¶
func SetGHPHosts ¶
SetGHPHosts sets the GitHub packages hosts
Types ¶
type ClaimSet ¶
type ClaimSet struct {
Access []struct {
Type string `json:"type"`
Name string `json:"name"`
Actions []string `json:"actions"`
} `json:"access"`
Context struct {
EntityKind string `json:"entity_kind"`
Kind string `json:"kind"`
Version int `json:"version"`
ComApostilleRoot string `json:"com.apostille.root"`
User string `json:"user"`
EntityReference string `json:"entity_reference"`
} `json:"context"`
Aud string `json:"aud"`
Exp int `json:"exp"`
Iss string `json:"iss"`
Iat int `json:"iat"`
Nbf int `json:"nbf"`
Sub string `json:"sub"`
}
https://docs.docker.com/registry/spec/auth/jwt/
{
"context": {
"com.apostille.root": "$disabled"
},
"aud": "docker.colofoo.net",
"exp": 1593910505,
"iss": "quay",
"iat": 1593906905,
"nbf": 1593906905,
"sub": "(anonymous)"
}
{
"access": [
{
"type": "repository",
"name": "presbrey/beyond",
"actions": [
"pull"
]
}
],
"context": {
"entity_kind": "appspecifictoken",
"kind": "user",
"version": 2,
"com.apostille.root": "$disabled",
"user": "joe",
"entity_reference": "4ac6f0e7-7bd2-4aea-9a77-738e1b98f22f"
},
"aud": null,
"exp": 1593911101,
"iss": "quay",
"iat": 1593907501,
"nbf": 1593907501,
"sub": "joe"
}
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
func (*Server) RegisterHandlers ¶
Click to show internal directories.
Click to hide internal directories.