Skip to content

Commit fe80940

Browse files
committed
feat: add parameters for finally tasks in PipelineRun
1 parent 9f9f195 commit fe80940

1 file changed

Lines changed: 10 additions & 0 deletions

File tree

src/service/pipeline.rs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,11 @@ impl PipelineService {
129129
let registry = url::hostname(&self.ctx.config.docker_registry_endpoint)?;
130130
let org = &self.ctx.config.namespace;
131131

132+
let webhook_endpoint = &self.ctx.config.webhook_endpoint;
133+
let webhook_url = format!("{webhook_endpoint}/v1/webhooks/tekton");
134+
135+
let secret = String::new();
136+
132137
// Define parameters for the PipelineRun
133138
let params = vec![
134139
("REPO_URL", format!("{git_endpoint}/{org}/{repo}.git")),
@@ -137,6 +142,11 @@ impl PipelineService {
137142
("TEST_IMAGE", format!("{registry}/{org}/{repo}-test:latest")),
138143
("COMMAND", format!("/app/{course}-tester")),
139144
("TEST_CASES_JSON", cases),
145+
("WEBHOOK_URL", webhook_url),
146+
("REPO", repo.to_string()),
147+
("COURSE", course.to_string()),
148+
("STAGE", stage.to_string()),
149+
("SECRET", secret),
140150
];
141151

142152
// Render a PipelineRun resource with the given name, labels, and params

0 commit comments

Comments
 (0)