-
Notifications
You must be signed in to change notification settings - Fork 73
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
Conversation
src/main/java/com/cloudbees/jenkins/plugins/awscredentials/AWSCredentialsImpl.java
Outdated
Show resolved
Hide resolved
src/main/java/com/cloudbees/jenkins/plugins/awscredentials/AWSCredentialsImpl.java
Outdated
Show resolved
Hide resolved
src/main/java/com/cloudbees/jenkins/plugins/awscredentials/AWSCredentialsImpl.java
Outdated
Show resolved
Hide resolved
src/main/java/com/cloudbees/jenkins/plugins/awscredentials/AWSCredentialsImpl.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this 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; |
There was a problem hiding this comment.
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; |
There was a problem hiding this comment.
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
ProxyConfiguration proxy = instance.proxy; | |
ProxyConfiguration proxy = instance != null ? instance.proxy : null; |
yes @jglick , it has been tested. |
@escoem could you cut a release to get this in? Thanks. |
This is a follow-up of
The idea is that AssumeRole gets the proxy configuration from Jenkins.