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
Example for usage in pipeline #86
Comments
Seconded, is there instructions anywhere on how to run gcloud commands with these credentials? |
i am also facing the same issue error: Credentials 'gcpgcr' is of type 'Google Service Account from private key' where 'org.jenkinsci.plugins.plaincredentials.FileCredentials' was expected any resolution will help us |
@rkamisetti792 we're using the helper function from this gist: with slight modifications (because the way credentials are stored might have changed since the time the gist was written):
then use it:
|
If you don't want to use a shared library I made it working with:
But I agree, I don't understand why such a plugin does not show how to simply use it :/ or I probably missed something but I mainly saw questions about usage. |
FTR not able to make it work using @sneko approach +1 to provide instructions here |
+1 on providing instructions about consuming the credentials-id in the jenking pipeline. |
Adding notes that I also can't make @sneko solution works. I got the following error message:
Changing |
You need to upload the JSON as a 'Secret file', not a 'Google Service Account from private key' File |
@eyalzek method really works, just had to rename |
Can you please provide example or some documentation on how to use it declarative or scripted pipeline? I used as below,
But it giving error like,
I also tried using as given in file https://github.com/jenkinsci/google-oauth-plugin/blob/develop/Jenkinsfile.google
But above gave me error like,
The text was updated successfully, but these errors were encountered: