File tree Expand file tree Collapse file tree 5 files changed +10
-0
lines changed
Expand file tree Collapse file tree 5 files changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -35,6 +35,7 @@ const Env = z.object({
3535 // Optional services
3636 TRIGGER_WARM_START_URL : z . string ( ) . optional ( ) ,
3737 TRIGGER_CHECKPOINT_URL : z . string ( ) . optional ( ) ,
38+ TRIGGER_METADATA_URL : z . string ( ) . optional ( ) ,
3839
3940 // Used by the workload manager, e.g docker/k8s
4041 DOCKER_NETWORK : z . string ( ) . default ( "host" ) ,
Original file line number Diff line number Diff line change @@ -61,6 +61,7 @@ class ManagedSupervisor {
6161 workloadApiDomain : env . TRIGGER_WORKLOAD_API_DOMAIN ,
6262 workloadApiPort : env . TRIGGER_WORKLOAD_API_PORT_EXTERNAL ,
6363 warmStartUrl : this . warmStartUrl ,
64+ metadataUrl : env . TRIGGER_METADATA_URL ,
6465 imagePullSecrets : env . KUBERNETES_IMAGE_PULL_SECRETS ?. split ( "," ) ,
6566 heartbeatIntervalSeconds : env . RUNNER_HEARTBEAT_INTERVAL_SECONDS ,
6667 snapshotPollIntervalSeconds : env . RUNNER_SNAPSHOT_POLL_INTERVAL_SECONDS ,
Original file line number Diff line number Diff line change @@ -45,6 +45,10 @@ export class DockerWorkloadManager implements WorkloadManager {
4545 runArgs . push ( `--env=TRIGGER_WARM_START_URL=${ this . opts . warmStartUrl } ` ) ;
4646 }
4747
48+ if ( this . opts . metadataUrl ) {
49+ runArgs . push ( `--env=TRIGGER_METADATA_URL=${ this . opts . metadataUrl } ` ) ;
50+ }
51+
4852 if ( this . opts . heartbeatIntervalSeconds ) {
4953 runArgs . push (
5054 `--env=TRIGGER_HEARTBEAT_INTERVAL_SECONDS=${ this . opts . heartbeatIntervalSeconds } `
Original file line number Diff line number Diff line change @@ -134,6 +134,9 @@ export class KubernetesWorkloadManager implements WorkloadManager {
134134 ...( this . opts . warmStartUrl
135135 ? [ { name : "TRIGGER_WARM_START_URL" , value : this . opts . warmStartUrl } ]
136136 : [ ] ) ,
137+ ...( this . opts . metadataUrl
138+ ? [ { name : "TRIGGER_METADATA_URL" , value : this . opts . metadataUrl } ]
139+ : [ ] ) ,
137140 ...( this . opts . heartbeatIntervalSeconds
138141 ? [
139142 {
Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ export interface WorkloadManagerOptions {
55 workloadApiDomain ?: string ; // If unset, will use orchestrator-specific default
66 workloadApiPort : number ;
77 warmStartUrl ?: string ;
8+ metadataUrl ?: string ;
89 imagePullSecrets ?: string [ ] ;
910 heartbeatIntervalSeconds ?: number ;
1011 snapshotPollIntervalSeconds ?: number ;
You can’t perform that action at this time.
0 commit comments