Files
fn-serverless/api/runner/docker-registry.go
Travis Reeder 10f3178ae9 Switching to new dep tool (#616)
* making things work

* #506 - Add ability to login to a private docker registry

* Rolling back "make things work" to test them out more.

* Rolling back "make things work" to test them out more.

* credentials from docker/config.json if ENV is missing

* should get docker auth info just in the init

* update glide lock

* update glide

* Switched to new go dep tool, glide is too frikin annoying.

* Updated circle builds to use dep

* Added GOPATH/bin to path.

* Added GOPATH/bin to path.

* Using regular make test, instead of docker one (not sure why it was using the docker one?).
2017-04-07 11:22:08 -07:00

23 lines
370 B
Go

package runner
import (
"strings"
)
type dockerRegistry struct {
Name string `json:"name"`
Username string `json:"username"`
Password string `json:"password"`
}
type dockerRegistries []dockerRegistry
func (t dockerRegistries) Find(name string) *dockerRegistry {
for _, v := range t {
if strings.HasSuffix(v.Name, name) {
return &v
}
}
return nil
}