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

[JENKINS-60057] AssumeRole does not honour proxy settings #71

Merged
merged 6 commits into from
Dec 16, 2019

Conversation

fbelzunc
Copy link
Contributor

@fbelzunc fbelzunc commented Nov 5, 2019

This is a follow-up of

The idea is that AssumeRole gets the proxy configuration from Jenkins.

@fbelzunc fbelzunc requested a review from escoem November 6, 2019 10:25
Copy link
Member

@jglick jglick left a comment

Choose a reason for hiding this comment

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

Looks right. Did anyone successfully test it?

Jenkins instance = Jenkins.getInstanceOrNull();

if (instance == null) {
return null;
Copy link
Member

Choose a reason for hiding this comment

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

Is .withClientConfiguration(null) even valid? I would just use .get() since in this context we expect Jenkins to be running.

return null;
}

ProxyConfiguration proxy = instance.proxy;
Copy link
Member

Choose a reason for hiding this comment

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

Instead of the above null check, could use

Suggested change
ProxyConfiguration proxy = instance.proxy;
ProxyConfiguration proxy = instance != null ? instance.proxy : null;

@escoem
Copy link
Contributor

escoem commented Dec 16, 2019

yes @jglick , it has been tested.

@escoem escoem merged commit 2273229 into jenkinsci:master Dec 16, 2019
@amuniz
Copy link
Member

amuniz commented Mar 22, 2021

@escoem could you cut a release to get this in? Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants