Skip to content

Commit 6344ef6

Browse files
committed
feat: [PIPE-29213]: Add network param + saving dir fix for BI local runner
1 parent c6bd4bc commit 6344ef6

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

engine/docker/convert.go

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,10 @@ import (
2121
"github.com/docker/go-connections/nat"
2222
)
2323

24+
const (
25+
buildCacheStepName = "harness-build-cache"
26+
)
27+
2428
// returns a container configuration.
2529
func toConfig(pipelineConfig *spec.PipelineConfig, step *spec.Step, image string) *container.Config {
2630
config := &container.Config{
@@ -131,7 +135,7 @@ func toHostConfig(pipelineConfig *spec.PipelineConfig, step *spec.Step) *contain
131135
func toNetConfig(pipelineConfig *spec.PipelineConfig, proc *spec.Step) *network.NetworkingConfig {
132136
// if the user overrides the default network we do not
133137
// attach to the user-defined network.
134-
if proc.Network != "" {
138+
if proc.Network != "" && proc.Name != buildCacheStepName {
135139
return &network.NetworkingConfig{}
136140
}
137141
endpoints := map[string]*network.EndpointSettings{}

ti/savings/cache/maven/parser.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ import (
1616
)
1717

1818
const (
19-
mavenReportPathRegex = "/harness/**/target/maven-incremental/*.xml"
19+
mavenReportPathRegex = "./**/target/maven-incremental/*.xml"
2020
tmpFilePath = "/tmp/maven-cache-marker"
2121
markerFilePerm = 0600
2222
markerDirPerm = 0755

0 commit comments

Comments
 (0)