summaryrefslogtreecommitdiff
path: root/vendor/github.com/projectatomic/buildah/util.go
diff options
context:
space:
mode:
authorGiuseppe Scrivano <gscrivan@redhat.com>2018-08-14 12:06:09 +0200
committerAtomic Bot <atomic-devel@projectatomic.io>2018-08-15 11:40:30 +0000
commite2b96e96f93d1da17b817eaa960b9d809bc61a14 (patch)
tree9dbf734f5f2021889666da7a738792635f2bf520 /vendor/github.com/projectatomic/buildah/util.go
parentcd7102a70e7f3555df832c4c1bcf958e121cbf4d (diff)
downloadpodman-e2b96e96f93d1da17b817eaa960b9d809bc61a14.tar.gz
podman-e2b96e96f93d1da17b817eaa960b9d809bc61a14.tar.bz2
podman-e2b96e96f93d1da17b817eaa960b9d809bc61a14.zip
vendor: update buildah version
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com> Closes: #1269 Approved by: rhatdan
Diffstat (limited to 'vendor/github.com/projectatomic/buildah/util.go')
-rw-r--r--vendor/github.com/projectatomic/buildah/util.go12
1 files changed, 9 insertions, 3 deletions
diff --git a/vendor/github.com/projectatomic/buildah/util.go b/vendor/github.com/projectatomic/buildah/util.go
index 4aa19b384..ef9be87fb 100644
--- a/vendor/github.com/projectatomic/buildah/util.go
+++ b/vendor/github.com/projectatomic/buildah/util.go
@@ -7,7 +7,7 @@ import (
"sync"
"github.com/containers/image/docker/reference"
- "github.com/containers/image/pkg/sysregistries"
+ "github.com/containers/image/pkg/sysregistriesv2"
"github.com/containers/image/types"
"github.com/containers/storage/pkg/archive"
"github.com/containers/storage/pkg/chrootarchive"
@@ -166,12 +166,18 @@ func (b *Builder) tarPath() func(path string) (io.ReadCloser, error) {
}
}
-// getRegistries obtains the list of registries defined in the global registries file.
+// getRegistries obtains the list of search registries defined in the global registries file.
func getRegistries(sc *types.SystemContext) ([]string, error) {
- searchRegistries, err := sysregistries.GetRegistries(sc)
+ var searchRegistries []string
+ registries, err := sysregistriesv2.GetRegistries(sc)
if err != nil {
return nil, errors.Wrapf(err, "unable to parse the registries.conf file")
}
+ for _, registry := range sysregistriesv2.FindUnqualifiedSearchRegistries(registries) {
+ if !registry.Blocked {
+ searchRegistries = append(searchRegistries, registry.URL)
+ }
+ }
return searchRegistries, nil
}