@@ -91,7 +91,6 @@ export class C2DEngineDocker extends C2DEngine {
9191 private trivyCachePath : string
9292 private cpuAllocations : Map < string , number [ ] > = new Map ( )
9393 private envCpuCoresMap : Map < string , number [ ] > = new Map ( )
94- private enableNetwork : boolean
9594
9695 public constructor (
9796 clusterConfig : C2DClusterInfo ,
@@ -115,7 +114,7 @@ export class C2DEngineDocker extends C2DEngine {
115114 this . paymentClaimInterval = clusterConfig . connection . paymentClaimInterval || 3600 // 1 hour
116115 this . scanImages = clusterConfig . connection . scanImages || false // default is not to scan images for now, until it's prod ready
117116 this . scanImageDBUpdateInterval = clusterConfig . connection . scanImageDBUpdateInterval
118- this . enableNetwork = clusterConfig . connection . enableNetwork ?? false
117+
119118 if (
120119 clusterConfig . connection . protocol &&
121120 clusterConfig . connection . host &&
@@ -236,7 +235,8 @@ export class C2DEngineDocker extends C2DEngine {
236235 { [ BASE_CHAIN_ID ] : [ getAddress ( '0xcb7Db55Ca9Aa9C3b25F5Bc266da63317fa02086a' ) ] }
237236 ]
238237 } ,
239- fees : benchmarkFees
238+ fees : benchmarkFees ,
239+ enableNetwork : true
240240 }
241241
242242 envConfig . environments . push ( benchmarkEnv )
@@ -367,7 +367,8 @@ export class C2DEngineDocker extends C2DEngine {
367367 queMaxWaitTime : 0 ,
368368 queMaxWaitTimeFree : 0 ,
369369 runMaxWaitTime : 0 ,
370- runMaxWaitTimeFree : 0
370+ runMaxWaitTimeFree : 0 ,
371+ enableNetwork : envDef . enableNetwork
371372 }
372373
373374 if ( envDef . storageExpiry !== undefined ) env . storageExpiry = envDef . storageExpiry
@@ -1836,7 +1837,7 @@ export class C2DEngineDocker extends C2DEngine {
18361837 }
18371838 ]
18381839 }
1839- if ( ! this . enableNetwork ) {
1840+ if ( ! env . enableNetwork ) {
18401841 hostConfig . NetworkMode = 'none' // no network inside the container
18411842 }
18421843 // disk
0 commit comments