Skip to content

Commit

Permalink
include: import disabled services for proper profile activation (#448)
Browse files Browse the repository at this point in the history
Signed-off-by: Nicolas De Loof <[email protected]>
  • Loading branch information
ndeloof authored Aug 25, 2023
1 parent ae43465 commit cda4df5
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions loader/include.go
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,12 @@ func importResources(model *types.Config, imported *types.Project, path []string
}
model.Services = append(model.Services, service)
}
for _, service := range imported.DisabledServices {
if _, ok := services[service.Name]; ok {
return fmt.Errorf("imported compose file %s defines conflicting service %s", path, service.Name)
}
model.Services = append(model.Services, service)
}
for n, network := range imported.Networks {
if _, ok := model.Networks[n]; ok {
return fmt.Errorf("imported compose file %s defines conflicting network %s", path, n)
Expand Down

0 comments on commit cda4df5

Please sign in to comment.