Skip to content

Conversation

@nalind
Copy link
Member

@nalind nalind commented Dec 12, 2018

This patch set updates the versions of the storage, image, and buildah libraries and enables blob and blobInfo caching. We switch back to the main containers/image repository, since it now supports registry names specified as IP addresses, and drop logic for setting the InsecureSkipTLSVerify flag, which the image library's registry client logic now sets automatically if we don't.

@openshift-ci-robot openshift-ci-robot added the size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. label Dec 12, 2018
@nalind nalind force-pushed the vendor-update branch 3 times, most recently from 00524e0 to 8db526a Compare December 12, 2018 16:32
@nalind
Copy link
Member Author

nalind commented Dec 12, 2018

/test all

@nalind
Copy link
Member Author

nalind commented Dec 13, 2018

/retest

Copy link
Contributor

@adambkaplan adambkaplan left a comment

Choose a reason for hiding this comment

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

A few questions (otherwise lgtm)

// By default, enable a blob cache, but allow it to be moved or
// disabled via the environment.
cfg.blobCache = "/var/cache/blobs"
if dir, isSet := os.LookupEnv("BUILD_BLOBCACHE"); isSet {
Copy link
Contributor

Choose a reason for hiding this comment

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

How will this be disabled - empty env valule?

Copy link
Contributor

Choose a reason for hiding this comment

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

please call this BUILD_ENABLE_BLOBCACHE or something that makes it clear it's an enablement (and then make it enable when the value is set to true (case insensitive))

Copy link
Member Author

Choose a reason for hiding this comment

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

Okay, changing it.

Copy link
Member Author

Choose a reason for hiding this comment

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

To be sure, this means we're going to need to update the build controller to enable the blob cache. By default, it isn't enabled, but we want to use it here. Blob info caching is enabled by default.

Copy link
Contributor

Choose a reason for hiding this comment

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

sorry I screwed this up. but i think BUILD_BLOBCACHE_DIR would be a better name.

Copy link
Contributor

Choose a reason for hiding this comment

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

(and ignore my comments about expecting a value of true)

} else {
glog.V(2).Infof("Registry for %q is not present in the registries configuration, assuming it is secure.", imageName)
}

Copy link
Contributor

Choose a reason for hiding this comment

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

I assume the designation of secure/insecure registries will be taken care of by copying in /etc/containers/registries.conf?

See openshift/origin#21653

Copy link
Contributor

Choose a reason for hiding this comment

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

@nalind did something get fixed in buildah that we don't need this any more?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes, containers/image#468 was merged.

Copy link
Member Author

Choose a reason for hiding this comment

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

@adambkaplan Yup, the way the builder expects the configuration to be provided to it hasn't changed, we just don't need to do this bit of work ourselves any more.

@bparees bparees self-assigned this Dec 13, 2018
@nalind nalind force-pushed the vendor-update branch 3 times, most recently from b757d4d to c7567ef Compare December 14, 2018 16:35
@nalind
Copy link
Member Author

nalind commented Dec 14, 2018

Backing out the changes to pay attention to the ImageOptimizationPolicy, which can be done in a different PR after this one.

@nalind
Copy link
Member Author

nalind commented Dec 14, 2018

/retest

@runcom
Copy link
Member

runcom commented Dec 19, 2018

This still needs a corresponding origin PR for the controller (e.g. openshift/origin#21613)

@bparees
Copy link
Contributor

bparees commented Jan 2, 2019

/retest

@runcom
Copy link
Member

runcom commented Jan 5, 2019

picked up this PR to bring in containers/buildah#1244 for testing till it gets merged and I'm seeing errors coming from pkg/errors and raven-go. I've been able to overcome that by sticking the lib in glide with:

+- package: github.com/pkg/errors
+  version: 645ef00459ed84a119197bfb8d8205042c6df63d
+- package: github.com/getsentry/raven-go
+  version: 32a13797442ccb601b11761d74232773c1402d14

it is related to getsentry/raven-go#225

@runcom
Copy link
Member

runcom commented Jan 5, 2019

The parallel pull + pgzip PR in Buildah has been merged. We could grab it here, I'm already testing with it.

nalind added 7 commits January 7, 2019 13:07
Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
Switch back to upstream containers/image, since it handles IP addresses
as registries.  Note that matching for entries in the insecure
registries list does not treat entries with no port number part as
matching any port, so it must often be specified.

This version also adds blob info caching by default.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
The image library's registry client now handles setting the
DockerInsecureSkipTLSVerify flag based on the registries configuration,
so we no longer need to do so ourselves.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
Use /var/cache/blobs, by default, for caching blobs.  Blob caching is
useful for avoiding the work of recompressing layers that we inherit
from a base image when we go to push the newly-built image.
If $BUILD_BLOBCACHE_DIR is set, we its value as the location, instead of
/var/cache/blobs.  Setting the variable to an empty value will disable
the cache.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
@openshift-ci-robot
Copy link
Contributor

openshift-ci-robot commented Jan 8, 2019

@nalind: The following tests failed, say /retest to rerun them all:

Test name Commit Details Rerun command
ci/prow/e2e-gcp-image-ecosystem c7567ef link /test e2e-gcp-image-ecosystem
ci/prow/e2e-gcp c7567ef link /test e2e-gcp
ci/prow/e2e-gcp-builds c7567ef link /test e2e-gcp-builds

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@mrunalp
Copy link
Member

mrunalp commented Jan 8, 2019

We need containers/buildah#1265 as well

@mrunalp
Copy link
Member

mrunalp commented Jan 8, 2019

/test e2e-aws

@nalind
Copy link
Member Author

nalind commented Jan 8, 2019

/test e2e-aws-builds

@nalind
Copy link
Member Author

nalind commented Jan 8, 2019

We need containers/buildah#1265 as well

Included as of #34 (comment).

@bparees
Copy link
Contributor

bparees commented Jan 8, 2019

one nit on the dir name, otherwise lgtm pending passing tests.

@bparees
Copy link
Contributor

bparees commented Jan 8, 2019

/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Jan 8, 2019
@openshift-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: bparees, nalind

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

The pull request process is described here

Details 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

@openshift-ci-robot openshift-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jan 8, 2019
@openshift-merge-robot openshift-merge-robot merged commit 3dc11b0 into openshift:master Jan 8, 2019
@nalind nalind deleted the vendor-update branch January 8, 2019 19:16
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/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants