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

Params declared in pre/postsubmit config are not passed to LighthouseJobSpec #1155

Closed
chrissena opened this issue Nov 13, 2020 · 1 comment · Fixed by #1266
Closed

Params declared in pre/postsubmit config are not passed to LighthouseJobSpec #1155

chrissena opened this issue Nov 13, 2020 · 1 comment · Fixed by #1266

Comments

@chrissena
Copy link
Contributor

It appears that the pipeline_run_params declared in the presubmit/postsubmit config in trigger.yaml are not copied to the generated LighthouseJobSpec and are therefore not available later to the subsequent code that generates the PipelineRun resource.

I had a browse of the source code and it looks like the bug is caused here:

func specFromJobBase(jb job.Base) v1alpha1.LighthouseJobSpec {
var namespace string
if jb.Namespace != nil {
namespace = *jb.Namespace
}
return v1alpha1.LighthouseJobSpec{
Agent: jb.Agent,
Job: jb.Name,
Namespace: namespace,
MaxConcurrency: jb.MaxConcurrency,
PodSpec: jb.Spec,
PipelineRunSpec: jb.PipelineRunSpec,
}
}

as the line PipelineRunParams: jb.PipelineRunParams is missing.

chrissena added a commit to chrissena/lighthouse that referenced this issue Nov 13, 2020
…om job.Base

add missing PipelineRunParams in specFromJobBase
add corresponding test case
fix jenkins-x#1155
@jenkins-x-bot
Copy link
Contributor

Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.
If this issue is safe to close now please do so with /close.
Provide feedback via https://jenkins-x.io/community.
/lifecycle stale

jstrachan pushed a commit to jstrachan/lighthouse that referenced this issue Mar 25, 2021
…om job.Base

add missing PipelineRunParams in specFromJobBase
add corresponding test case
fix jenkins-x#1155
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants