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

Bug 1882556: Access git over https for tests #25625

Merged
merged 1 commit into from Oct 29, 2020
Merged

Bug 1882556: Access git over https for tests #25625

merged 1 commit into from Oct 29, 2020

Conversation

coreydaley
Copy link
Member

Replace git:// urls with https:// urls for all tests

@openshift-ci-robot openshift-ci-robot added bugzilla/severity-low Referenced Bugzilla bug's severity is low for the branch this PR is targeting. bugzilla/valid-bug Indicates that a referenced Bugzilla bug is valid for the branch this PR is targeting. labels Oct 23, 2020
@openshift-ci-robot
Copy link

@coreydaley-redhat: This pull request references Bugzilla bug 1882556, which is valid. The bug has been moved to the POST state. The bug has been updated to refer to the pull request using the external bug tracker.

3 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target release (4.7.0) matches configured target release for branch (4.7.0)
  • bug is in the state NEW, which is one of the valid states (NEW, ASSIGNED, ON_DEV, POST, POST)

In response to this:

Bug 1882556: Access git over https for tests

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.

@coreydaley
Copy link
Member Author

/assign @adambkaplan

@coreydaley
Copy link
Member Author

/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.

I'd like to ensure that we have at least one e2e test that pulls via the git: protocol. This test would need to check that we have a cluster-wide proxy configured before running.

@coreydaley
Copy link
Member Author

I'd like to ensure that we have at least one e2e test that pulls via the git: protocol. This test would need to check that we have a cluster-wide proxy configured before running.

So, we would need to fix the proxy (according to the bugzilla) so that git:// urls can be proxied. Should that be a JIRA then as it is probably a bit more work. Or are you saying that we need a test that uses a git:// url and make sure that the proxy is NOT configured so that it has a chance to work?

@adambkaplan
Copy link
Contributor

Or are you saying that we need a test that uses a git:// url and make sure that the proxy is NOT configured so that it has a chance to work?

Correct - we should have a test that clones source via git://, but when the test starts it checks if a proxy has been configured, skipping if a proxy is present. This should be fairly straightforward (psudo-code here):

func hasProxy() (bool, error) {
    proxy, err := e.ConfigClient.Proxies().Get(ctx, "cluster", metav1.GetOptions{})
    if err != nil && !kerrors.IsNotFound(err) {
        return false, error
    }
    if kerrors.IsNotFound(err) {
        return false, nil
    }
    return len(proxy.Status.HTTPProxy) > 0 || len(proxy.Status.HTTPSProxy) > 0, nil
}

@coreydaley
Copy link
Member Author

/retest

2 similar comments
@coreydaley
Copy link
Member Author

/retest

@coreydaley
Copy link
Member Author

/retest

@wewang58
Copy link
Contributor

/bugzilla cc-qa

@openshift-ci-robot
Copy link

@wewang58: This pull request references Bugzilla bug 1882556, which is valid.

3 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target release (4.7.0) matches configured target release for branch (4.7.0)
  • bug is in the state POST, which is one of the valid states (NEW, ASSIGNED, ON_DEV, POST, POST)

Requesting review from QA contact:
/cc @wewang58

In response to this:

/bugzilla cc-qa

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.

@coreydaley
Copy link
Member Author

@adambkaplan ptal

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.

/approve

Minor suggestions, otherwise looks good.

test/extended/builds/clone_git_protocol.go Outdated Show resolved Hide resolved
test/extended/builds/clone_git_protocol.go Outdated Show resolved Hide resolved
test/extended/util/proxy.go Outdated Show resolved Hide resolved
@coreydaley
Copy link
Member Author

@adambkaplan all suggestions have been applied, ptal

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.

/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Oct 28, 2020
@coreydaley
Copy link
Member Author

/retest

@coreydaley
Copy link
Member Author

/assign @soltysh

@wewang58
Copy link
Contributor

Using cluster-bot to launch cluster to test it
/lgtm

Copy link
Member

@soltysh soltysh left a comment

Choose a reason for hiding this comment

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

/lgtm cancel

test/extended/builds/clone_git_protocol.go Outdated Show resolved Hide resolved
@openshift-ci-robot openshift-ci-robot removed the lgtm Indicates that a PR is ready to be merged. label Oct 29, 2020
Replace git:// urls with https:// urls for all tests
@coreydaley
Copy link
Member Author

@soltysh Updated per your comment, ptal.

Copy link
Member

@soltysh soltysh left a comment

Choose a reason for hiding this comment

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

/lgtm
/approve

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Oct 29, 2020
@openshift-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: adambkaplan, coreydaley-redhat, soltysh, wewang58

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

@openshift-ci-robot openshift-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Oct 29, 2020
@openshift-merge-robot openshift-merge-robot merged commit 1bc6351 into openshift:master Oct 29, 2020
@openshift-ci-robot
Copy link

@coreydaley-redhat: All pull requests linked via external trackers have merged:

Bugzilla bug 1882556 has been moved to the MODIFIED state.

In response to this:

Bug 1882556: Access git over https for tests

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.

@adambkaplan
Copy link
Contributor

/cherrypick release-4.6

@adambkaplan
Copy link
Contributor

/cherry-pick release-4.6

@openshift-cherrypick-robot

@adambkaplan: new pull request created: #25951

In response to this:

/cherrypick release-4.6

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.

@adambkaplan
Copy link
Contributor

/cherry-pick release-4.5

@openshift-cherrypick-robot

@adambkaplan: new pull request could not be created: failed to create pull request against openshift/origin#release-4.6 from head openshift-cherrypick-robot:cherry-pick-25625-to-release-4.6: status code 422 not one of [201], body: {"message":"Validation Failed","errors":[{"resource":"PullRequest","code":"custom","message":"A pull request already exists for openshift-cherrypick-robot:cherry-pick-25625-to-release-4.6."}],"documentation_url":"https://docs.github.com/rest/reference/pulls#create-a-pull-request"}

In response to this:

/cherry-pick release-4.6

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.

@openshift-cherrypick-robot

@adambkaplan: #25625 failed to apply on top of branch "release-4.5":

Applying: Bug 1882556: Access git over https for tests
Using index info to reconstruct a base tree...
M	test/extended/testdata/bindata.go
M	test/extended/testdata/cmd/test/cmd/env.sh
M	test/extended/util/annotate/generated/zz_generated.annotations.go
Falling back to patching base and 3-way merge...
Auto-merging test/extended/util/annotate/generated/zz_generated.annotations.go
CONFLICT (content): Merge conflict in test/extended/util/annotate/generated/zz_generated.annotations.go
Auto-merging test/extended/testdata/cmd/test/cmd/env.sh
Auto-merging test/extended/testdata/bindata.go
error: Failed to merge in the changes.
hint: Use 'git am --show-current-patch=diff' to see the failed patch
Patch failed at 0001 Bug 1882556: Access git over https for tests
When you have resolved this problem, run "git am --continue".
If you prefer to skip this patch, run "git am --skip" instead.
To restore the original branch and stop patching, run "git am --abort".

In response to this:

/cherry-pick release-4.5

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.

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. bugzilla/severity-low Referenced Bugzilla bug's severity is low for the branch this PR is targeting. bugzilla/valid-bug Indicates that a referenced Bugzilla bug is valid for the branch this PR is targeting. lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants