Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

service-catalog cross build test with dind #8734

Merged
merged 1 commit into from
Jul 20, 2018

Conversation

MHBauer
Copy link
Contributor

@MHBauer MHBauer commented Jul 19, 2018

I created this by guessing that I need a docker-in-docker enabled instance.

I found the variable DOCKER_IN_DOCKER_ENABLED, and searched for it.

I picked this to copy from
https://github.com/kubernetes/test-infra/blob/68c68683a066e7b9986113c73a6dcb0f48775ef9/config/jobs/kubernetes-sigs/cluster-api-provider-openstack/cluster-api-provider-openstack-presubmits.yaml
because it's in the new location for config, so I figure that means someone has looked at it.

I didn't totally copy it, because I don't know what some of the args are, such as:

    labels: 
        preset-service-account: "true"

and - "--upload=gs://kubernetes-jenkins/pr-logs"

I also don't know how much memory it needs, so I dropped the 6G requirement. I do not know what the default is, but I'm going to hope it's enough for now.

@k8s-ci-robot k8s-ci-robot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Jul 19, 2018
@krzyzacy
Copy link
Member

/assign @BenTheElder
do we still need to mount docker-graph as an emptydir?

@MHBauer
Copy link
Contributor Author

MHBauer commented Jul 19, 2018

fixed the bad indent on the yaml.

@MHBauer
Copy link
Contributor Author

MHBauer commented Jul 19, 2018

okay, should be really real this time. where's yaml-fmt when you need it?

always_run: true
skip_report: false
rerun_command: "/test pull-service-catalog-xbuild"
trigger: "/test( all| pull-service-catalog-xbuild)"
Copy link
Member

Choose a reason for hiding this comment

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

you probably want to copy the above regex

always_run: true
skip_report: false
rerun_command: "/test pull-service-catalog-xbuild"
trigger: "(?m)^/test( all|pull-service-catalog-xbuild)\\s*"
Copy link
Member

Choose a reason for hiding this comment

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

lol, /test (all|pull-service-catalog-xbuild)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

how did that space get in there, 😞

@MHBauer MHBauer force-pushed the svc-cat-xbuild branch 2 times, most recently from 0b79da5 to 063a59d Compare July 20, 2018 01:15
@MHBauer
Copy link
Contributor Author

MHBauer commented Jul 20, 2018

I have a very powerful case of "the dumb" today. How can I run this check locally?

@MHBauer
Copy link
Contributor Author

MHBauer commented Jul 20, 2018

yay green.

- "images-all"
- "svcat-all"
env:
- name: DOCKER_IN_DOCKER_ENABLED
Copy link
Member

Choose a reason for hiding this comment

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

I'm going to turn this into a preset soon. Initially we didn't because we wanted to discourage depending on it (I only initially built the support to help us get the rest of our existing jobs onto Prow), but so far it works just fine.

This must be paired with an emptyDir volume for the the graph storage (which is remapped /var/lib/docker for :reasons:, we should probably unset the option that changes that). Unless things have improved this is necessary to avoid issues with overlays on overlays. Existing docker-in-docker jobs should have this.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

What is a preset?

I was basing off of, which has preset-service-account
https://github.com/kubernetes/test-infra/blob/68c68683a066e7b9986113c73a6dcb0f48775ef9/config/jobs/kubernetes-sigs/cluster-api-provider-openstack/cluster-api-provider-openstack-presubmits.yaml

It does not have a emptydir, so maybe it's a bad example, oops.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Copy link
Member

Choose a reason for hiding this comment

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

- args:
- "--repo=sigs.k8s.io/$(REPO_NAME)=$(PULL_REFS)"
- "--root=/go/src/github.com/kubernetes-incubator/$(REPO_NAME)"
- "--timeout=90"
Copy link
Member

Choose a reason for hiding this comment

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

does this take 90 minutes? if so, does it use many cores / gbs of ram? if it does, we should add a resource request. if it doesn't do any of those things, we should tighten the timeout.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

it's a go build, so it'll use cores we give it. What's the default? 1/2/500millicore?

the two make targets together take about 50minutes on travis, but much less locally, so I'm not sure how to gauge.

This is pretty much the most cpu intensive workload we have. Others take long, but are filled with pauses and inefficiencies. This should be straight compiling.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'll change it to 60, if that sounds okay. What is the default?

Copy link
Member

Choose a reason for hiding this comment

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

default is infinite I think

Copy link
Contributor Author

@MHBauer MHBauer left a comment

Choose a reason for hiding this comment

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

@BenTheElder thanks for help. didn't mean to do a review, oops.

- "images-all"
- "svcat-all"
env:
- name: DOCKER_IN_DOCKER_ENABLED
Copy link
Contributor Author

Choose a reason for hiding this comment

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

What is a preset?

I was basing off of, which has preset-service-account
https://github.com/kubernetes/test-infra/blob/68c68683a066e7b9986113c73a6dcb0f48775ef9/config/jobs/kubernetes-sigs/cluster-api-provider-openstack/cluster-api-provider-openstack-presubmits.yaml

It does not have a emptydir, so maybe it's a bad example, oops.

- args:
- "--repo=sigs.k8s.io/$(REPO_NAME)=$(PULL_REFS)"
- "--root=/go/src/github.com/kubernetes-incubator/$(REPO_NAME)"
- "--timeout=90"
Copy link
Contributor Author

Choose a reason for hiding this comment

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

it's a go build, so it'll use cores we give it. What's the default? 1/2/500millicore?

the two make targets together take about 50minutes on travis, but much less locally, so I'm not sure how to gauge.

This is pretty much the most cpu intensive workload we have. Others take long, but are filled with pauses and inefficiencies. This should be straight compiling.

@k8s-ci-robot k8s-ci-robot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Jul 20, 2018
@krzyzacy
Copy link
Member

/lgtm
/hold

@k8s-ci-robot k8s-ci-robot added do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. lgtm "Looks good to me", indicates that a PR is ready to be merged. labels Jul 20, 2018
@krzyzacy
Copy link
Member

/lgtm cancel
whoops, if you are using kubekins image, you'll still need preset-service-account

@k8s-ci-robot k8s-ci-robot removed the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jul 20, 2018
@MHBauer
Copy link
Contributor Author

MHBauer commented Jul 20, 2018

lol, there's a test for it. Why didn't that show up earlier?

I0720 20:13:22.986] --- FAIL: TestValidPresets (0.00s)
I0720 20:13:22.986] 	jobs_test.go:695: Error in presubmit "pull-service-catalog-xbuild": cannot find service account preset

Is there a way to run these tests? I'll go search for what's already failed and try to read some.

@MHBauer
Copy link
Contributor Author

MHBauer commented Jul 20, 2018

I understand now. I'll add that back in.

@krzyzacy
Copy link
Member

from gubernator link, you can find the test command: bazel test //config/tests/jobs:go_default_test

@krzyzacy
Copy link
Member

I cannot find the previous snapshot, but I assume you had it before and removed it at some point?

@krzyzacy
Copy link
Member

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jul 20, 2018
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: krzyzacy, MHBauer

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

The pull request process is described here

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

@MHBauer
Copy link
Contributor Author

MHBauer commented Jul 20, 2018

snapshot of what?

@krzyzacy
Copy link
Member

how your initial commit looks like :-)

@MHBauer
Copy link
Contributor Author

MHBauer commented Jul 20, 2018

I never put it in there, but I mentioned it in the original comment that I saw it and didn't know what it did.

@MHBauer
Copy link
Contributor Author

MHBauer commented Jul 20, 2018

Does this seem sane now?

@krzyzacy
Copy link
Member

/hold cancel
(feel free to /hold cancel yourself in the future, as long as you have lgtm and approve)

@k8s-ci-robot k8s-ci-robot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jul 20, 2018
@k8s-ci-robot k8s-ci-robot merged commit c95b9d3 into kubernetes:master Jul 20, 2018
@k8s-ci-robot
Copy link
Contributor

@MHBauer: Updated the job-config configmap using the following files:
- key service-catalog-presubmits.yaml using file config/jobs/kubernetes-incubator/service-catalog/service-catalog-presubmits.yaml

In response to this:

I created this by guessing that I need a docker-in-docker enabled instance.

I found the variable DOCKER_IN_DOCKER_ENABLED, and searched for it.

I picked this to copy from
https://github.com/kubernetes/test-infra/blob/68c68683a066e7b9986113c73a6dcb0f48775ef9/config/jobs/kubernetes-sigs/cluster-api-provider-openstack/cluster-api-provider-openstack-presubmits.yaml
because it's in the new location for config, so I figure that means someone has looked at it.

I didn't totally copy it, because I don't know what some of the args are, such as:

   labels: 
       preset-service-account: "true"

and - "--upload=gs://kubernetes-jenkins/pr-logs"

I also don't know how much memory it needs, so I dropped the 6G requirement. I do not know what the default is, but I'm going to hope it's enough for now.

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.

@MHBauer
Copy link
Contributor Author

MHBauer commented Jul 20, 2018

Yes, you did lgtm it again. I like a little bit more context I suppose.

@krzyzacy
Copy link
Member

lol, lgtm means you are doing good :-)

@MHBauer
Copy link
Contributor Author

MHBauer commented Jul 20, 2018

@krzyzacy alright, I need some help kubernetes-retired/service-catalog#2212 not sure if this takes longer to take effect, or if we're having more repo permission issues, or how to debug this.

@MHBauer MHBauer deleted the svc-cat-xbuild branch July 20, 2018 20:53
containers:
- image: gcr.io/k8s-testimages/kubekins-e2e:v20180716-9145034c9-1.10
args:
- "--repo=sigs.k8s.io/$(REPO_NAME)=$(PULL_REFS)"
Copy link
Member

Choose a reason for hiding this comment

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

this should be github.com/kubernetes-incubator instead of sigs.k8s.io

Copy link
Contributor Author

Choose a reason for hiding this comment

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

of course it should 🙃

Copy link
Contributor Author

Choose a reason for hiding this comment

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

followup fix in #8763

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. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants