Skip to content

Commit

Permalink
fix DownloadDstDir bug
Browse files Browse the repository at this point in the history
Signed-off-by: JimmyYang20 <[email protected]>
  • Loading branch information
JimmyYang20 committed Oct 27, 2021
1 parent 1c5c537 commit a9d6645
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion pkg/globalmanager/runtime/storage_initializer_injector.go
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,12 @@ func (m *MountURL) parseDownloadPath() {
m.ContainerPath = filepath.Join(m.MountPath, m.u.Host+m.u.Path)

m.DownloadSrcURL = m.URL
m.DownloadDstDir, _ = filepath.Split(m.ContainerPath)

tempPath := m.ContainerPath
if filepath.Ext(m.URL) == "" {
tempPath = filepath.Join(tempPath, "temp.txt")
}
m.DownloadDstDir, _ = filepath.Split(tempPath)

break
}
Expand Down

0 comments on commit a9d6645

Please sign in to comment.