Skip to content

Commit

Permalink
fix(compose): support image names with dot
Browse files Browse the repository at this point in the history
Signed-off-by: Aleksei Igrychev <aleksei.igrychev@palark.com>
  • Loading branch information
alexey-igrychev committed Sep 18, 2024
1 parent b3772c0 commit fbd5b5a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion cmd/werf/compose/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ func (d *composeCmdData) GetOrExtractImagesToProcess(werfConfig *config.WerfConf

// Replace all special characters in image name with empty string to find the same image name in werf config.
replaceAllFunc := func(s string) string {
for _, l := range []string{"_", "-", "/"} {
for _, l := range []string{"_", "-", "/", "."} {
s = strings.ReplaceAll(s, l, "")
}
return s
Expand Down
2 changes: 1 addition & 1 deletion pkg/build/build_phase.go
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ func GenerateImageEnv(werfImageName, imageName string) string {
imageEnvName = "WERF_DOCKER_IMAGE_NAME"
} else {
werfImageName := strings.ToUpper(werfImageName)
for _, l := range []string{"/", "-"} {
for _, l := range []string{"/", "-", "."} {
werfImageName = strings.ReplaceAll(werfImageName, l, "_")
}

Expand Down

0 comments on commit fbd5b5a

Please sign in to comment.