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 plugin Json or P12 key are not found and saved empty #13

Closed
anniekvandijk opened this issue Nov 28, 2017 · 10 comments
Closed

Jenkins plugin Json or P12 key are not found and saved empty #13

anniekvandijk opened this issue Nov 28, 2017 · 10 comments

Comments

@anniekvandijk
Copy link

When I try to push a Docker image to GGloud i get this stacktrace

com.google.jenkins.plugins.credentials.oauth.GoogleRobotPrivateKeyCredentials$AccountIdNotSetException
	at com.google.jenkins.plugins.credentials.oauth.GoogleRobotPrivateKeyCredentials.getGoogleCredential(GoogleRobotPrivateKeyCredentials.java:181)
	at com.google.jenkins.plugins.credentials.oauth.GoogleRobotPrivateKeyCredentials.getGoogleCredential(GoogleRobotPrivateKeyCredentials.java:45)
	at com.google.jenkins.plugins.credentials.oauth.GoogleRobotCredentials.getAccessToken(GoogleRobotCredentials.java:101)
	at com.google.jenkins.plugins.googlecontainerregistryauth.GoogleContainerRegistryCredentialModule.getToken(GoogleContainerRegistryCredentialModule.java:73)

When I open my credentials the file is gone.

image

Key files are generated but not found. Also the files are empty

image

Jenkins for Windows ver. 2.73.3
Google OAuth Credentials plugin 0.5

@anniekvandijk anniekvandijk changed the title Jenkins plugin Json or P12 key are not saved Jenkins plugin Json or P12 key are not found and saved empty Nov 28, 2017
@DzianisH
Copy link

DzianisH commented Jan 19, 2018

I have totally the same problem. I've tried to populate *.json and *.p12 files on Jenkins manually but it wasn't help me.
Can you please provide fix date or some workaround for this issue, because for now it's impossible to connect Jenkins to GCloud.
Jenkins 2.91, windows

@proskehy
Copy link

I have the same issue, is anyone looking into this?

@sortidocorps
Copy link

I have the same issue to, nobody find a bypass ? or a way to put manualy the json file ? ty.

@mneil
Copy link

mneil commented Apr 4, 2018

Version 0.5 doesn't seem to have this issue. Check that the user you are running Jenkins on has permission to change file permissions.

I tried on a fresh install of the latest version of Jenkins as well as a slightly older version. Both worked as long as my Jenkins user had sufficient privileges.

@proskehy
Copy link

proskehy commented Apr 5, 2018

How do I go about checking that? Jenkins is a Windows service and I start the job as an admin user.

@mneil
Copy link

mneil commented Apr 5, 2018

Actually, I'm sorry, 0.6-SNAPSHOT has this fixed. 0.5 still has the issue. It looks like it's mostly ready to deploy. I'm not sure what the holdup is but even getting the snapshot version on maven would be helpful.

@proskehy
Copy link

proskehy commented Apr 5, 2018

Thank you for the confirmation. Is there a way for us to get the 0.6 version before it's officially released?

@barrymac
Copy link

@mneil I tried this with 0.6-SNAPSHOT I built and manually installed and still got the problem, any patch needed?

@proskehy I ran mvn install in this repository and copied the hpi file to the plugins directory in place of the the installed one.

@soartseng
Copy link

Today, I got the 0.6 version updated announcement.
In 0.6 version, I have the same problem in Jenkins "Free-style" project.
Bit I can success to checkout in Jenkins "pipeline" project.
I just copy the "checkout syntax" in others project and replace 2 parts of the syntax to the right:

  1. credentialsid -> replace to your right credentials id that you created Google Service Account from private key in jenkins.
  2. url ->replace to your google source repository url

@stephenashank
Copy link
Contributor

Resolved with #19 and #48.

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

No branches or pull requests

8 participants