Skip to content

Commit

Permalink
feat: update debug mode build using consolidated multistage dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
heronimus committed Jan 15, 2024
1 parent 598a34f commit e400fce
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions common/tea_cmd/docker.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,14 @@ func dockerCompose(args ...string) error {
}

func dockerComposeWithCfg(cfg config.Config, args ...string) error {
yml := ""
yml := path.Join(cfg.RootDir, "docker-compose.yml")

if !cfg.Debug {
yml = path.Join(cfg.RootDir, "docker-compose.yml")
args = append([]string{"compose", "-f", yml}, args...)
} else {
yml = path.Join(cfg.RootDir, ".ide-debug/docker-compose.debug.yml")
ymlDebug := path.Join(cfg.RootDir, ".ide-debug/compose.debug.override.yml")
args = append([]string{"compose", "-f", yml, "-f", ymlDebug}, args...)
}
args = append([]string{"compose", "-f", yml}, args...)
cmd := exec.Command("docker", args...)
cmd.Stdout = os.Stdout
cmd.Stderr = os.Stderr
Expand Down

0 comments on commit e400fce

Please # to comment.