File size: 813 Bytes
d61821a
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
diff --git a/functions/concrete/run/runner.go b/functions/concrete/run/runner.go
index af053eb4..5088598c 100644
--- a/functions/concrete/run/runner.go
+++ b/functions/concrete/run/runner.go
@@ -304,7 +304,10 @@ func (r *Runner) finalize(ctx context.Context) (cacheErr, artifactErr error) {
 		})
 	}
 
-	if len(r.config.ArtifactsArchive) > 0 {
+	// Mirror abstract's writeUploadArtifacts ErrSkipBuildStage guard: with
+	// no server URL there is nowhere to upload to, so skip the section
+	// entirely rather than invoking artifacts-uploader with --url "".
+	if len(r.config.ArtifactsArchive) > 0 && r.env.BaseURL != "" {
 		_ = r.section(ctx, uploadSection, func(ctx context.Context, e *env.Env) error {
 			for _, artifact := range r.config.ArtifactsArchive {
 				if err := artifact.Run(ctx, e); err != nil {