SecretParam 'GITHUB_API_TOKEN' is used before it is resolved.
All the steps you have taken are correct. This seems like a bug in GoCD. I
would suggest opening an issue here https://github.com/gocd/gocd/issues.
I wonder if it’s because a pipeline is not created (yet) at the time of “Test connection” – assuming this is at the time of creation of the pipeline. If that’s the case, maybe trying it after the pipeline is created might be a way forward.
Cheers,
Aravind
Hello Helge,
A question regarding Pipelines as code: When exporting the pipeline, e.g. as JSON, the password (or the placeholder) is exported as encrypted string. This is not portable between GoCD instances. Is it somehow possible to specify it in JSON as plain text?
I think not. At the time the export happens, the pipeline does not even know that the secret is defined using a secret parameter. Same with templates. So, you’ll need to replace is after the export. :(
Cheers,
Aravind