Skip to content

Commit d496bcd

Browse files
authored
fix(studio): format snippets folder container path (#4661)
1 parent beefa70 commit d496bcd

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

internal/start/start.go

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1146,7 +1146,8 @@ EOF
11461146

11471147
// Mount snippets directory for Studio to access
11481148
hostSnippetsPath := filepath.Join(workdir, utils.SnippetsDir)
1149-
binds = append(binds, fmt.Sprintf("%s:%s:rw", hostSnippetsPath, hostSnippetsPath))
1149+
containerSnippetsPath := utils.ToDockerPath(hostSnippetsPath)
1150+
binds = append(binds, fmt.Sprintf("%s:%s:rw", hostSnippetsPath, containerSnippetsPath))
11501151
binds = utils.RemoveDuplicates(binds)
11511152
if _, err := utils.DockerStart(
11521153
ctx,
@@ -1166,8 +1167,8 @@ EOF
11661167
fmt.Sprintf("LOGFLARE_URL=http://%v:4000", utils.LogflareId),
11671168
fmt.Sprintf("NEXT_PUBLIC_ENABLE_LOGS=%v", utils.Config.Analytics.Enabled),
11681169
fmt.Sprintf("NEXT_ANALYTICS_BACKEND_PROVIDER=%v", utils.Config.Analytics.Backend),
1169-
"EDGE_FUNCTIONS_MANAGEMENT_FOLDER=" + filepath.Join(workdir, utils.FunctionsDir),
1170-
"SNIPPETS_MANAGEMENT_FOLDER=" + hostSnippetsPath,
1170+
"EDGE_FUNCTIONS_MANAGEMENT_FOLDER=" + utils.ToDockerPath(filepath.Join(workdir, utils.FunctionsDir)),
1171+
"SNIPPETS_MANAGEMENT_FOLDER=" + containerSnippetsPath,
11711172
// Ref: https://github.com/vercel/next.js/issues/51684#issuecomment-1612834913
11721173
"HOSTNAME=0.0.0.0",
11731174
},

0 commit comments

Comments
 (0)