Skip to content

Commit

Permalink
fix: create cronjob
Browse files Browse the repository at this point in the history
  • Loading branch information
msvticket committed Jan 10, 2024
1 parent b1508fc commit 561929c
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions pkg/plugins/trigger/periodic.go
Original file line number Diff line number Diff line change
Expand Up @@ -386,8 +386,7 @@ func (pa *PeriodicAgent) constructCronJob(resourceName, configMapName string, la
if !found {
serviceAccount = "lighthouse-webhooks"
}
return (&applybatchv1.CronJobApplyConfiguration{}).
WithName(resourceName).
return applybatchv1.CronJob(resourceName, pa.Namespace).
WithLabels(labels).
WithSpec((&applybatchv1.CronJobSpecApplyConfiguration{}).
WithJobTemplate((&applybatchv1.JobTemplateSpecApplyConfiguration{}).
Expand Down

0 comments on commit 561929c

Please sign in to comment.