-
Notifications
You must be signed in to change notification settings - Fork 7
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
aws credentials entered into project config not persisting across reloading of page. #3
Comments
On this scenario, it is resorting to the default behaviour, when no credentials are present. Did you upgrade the credentials and the AWS Credentials plugin as well? |
All applications and Plugins are the latest version or up-to-date. My point is that when I input my credentials and save the build configuration, exit the page and re-enter the build configuration, no credentials are listed in my build configuration. I shall try this first by re-creating the docker container and if that is unsuccessful I shall see if the problem goes away if Jenkins is run outside of docker. EDIT: I just tried rebuilding the docker image with |
@aldrinleal OK, this is embarrassing... I rebuild the image again, this time not installing awscli in the Dockerfile(as I had done previously). The "good" point here is that I didn't need to include this step at after all, helping reduce the size of my docker container/image. I got too caught up in the unorthodox behavior of this plugin to notice this simple mistake. Presumably this plugin functions normally even when it appears like it might not be. Closing issue. Thanks for your help. |
I believe a Jenkinsfile needs to be checked out first, so I guess the answer is no, right? |
I'm facing this issue now. Can you please help with the workaround? The selection resets even after saving/applying changes to the pipeline and the build fails as it doesn't recognize the credentials. |
I am running Jenkins ver. 2.121.3 as a docker container.
Docker ver. 18.06.1-ce.
I am having difficulty accessing aws credentials through Jenkins. I tried two approaches:
The Error from my project build:
Started by user admin
Building in workspace /var/jenkins_home/workspace/CodeCommit-Project
FATAL: Meh
com.amazonaws.SdkClientException: Unable to load AWS credentials from any provider in the chain: [EnvironmentVariableCredentialsProvider: Unable to load AWS credentials from environment variables (AWS_ACCESS_KEY_ID (or AWS_ACCESS_KEY) and AWS_SECRET_KEY (or AWS_SECRET_ACCESS_KEY)), SystemPropertiesCredentialsProvider: Unable to load AWS credentials from Java system properties (aws.accessKeyId and aws.secretKey), com.amazonaws.auth.profile.ProfileCredentialsProvider@1fd4d944: profile file cannot be null, com.amazonaws.auth.EC2ContainerCredentialsProviderWrapper@7d32b41c: The requested metadata is not found at http://169.254.169.254/latest/meta-data/iam/security-credentials/]
at com.amazonaws.auth.AWSCredentialsProviderChain.getCredentials(AWSCredentialsProviderChain.java:136)
at br.com.ingenieux.jenkins.plugins.codecommit.CodeCommitRequestSigner.<init>(CodeCommitRequestSigner.java:35)
at br.com.ingenieux.jenkins.plugins.codecommit.CodeCommitURLHelper.fetchCodeCommitRepositoryNames(CodeCommitURLHelper.java:156)
at br.com.ingenieux.jenkins.plugins.codecommit.CodeCommitURLHelper.decorate(CodeCommitURLHelper.java:123)
Caused: hudson.plugins.git.GitException: Meh
at br.com.ingenieux.jenkins.plugins.codecommit.CodeCommitURLHelper.decorate(CodeCommitURLHelper.java:129)
at hudson.plugins.git.GitSCM.createClient(GitSCM.java:823)
at hudson.plugins.git.GitSCM.createClient(GitSCM.java:812)
at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1180)
at hudson.scm.SCM.checkout(SCM.java:504)
at hudson.model.AbstractProject.checkout(AbstractProject.java:1208)
at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:574)
at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86)
at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:499)
at hudson.model.Run.execute(Run.java:1798)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
at hudson.model.ResourceController.execute(ResourceController.java:97)
at hudson.model.Executor.run(Executor.java:429)
Finished: FAILURE
I have aws cli installed in the docker container. Could this be causing conflict? I initially did so because I thought it would be a prerequisite to getting CodeCommit to work with Jenkins.
The text was updated successfully, but these errors were encountered: