mirror of
https://github.com/docker/compose.git
synced 2025-07-23 13:45:00 +02:00
Prefer external.name over x-aws-securitygroup
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
This commit is contained in:
parent
0c1de64c84
commit
46cebb3194
@ -524,7 +524,11 @@ func createCloudMap(project *types.Project, template *cloudformation.Template) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func convertNetwork(project *types.Project, net types.NetworkConfig, vpc string, template *cloudformation.Template) string {
|
func convertNetwork(project *types.Project, net types.NetworkConfig, vpc string, template *cloudformation.Template) string {
|
||||||
|
if net.External.External {
|
||||||
|
return net.Name
|
||||||
|
}
|
||||||
if sg, ok := net.Extensions[extensionSecurityGroup]; ok {
|
if sg, ok := net.Extensions[extensionSecurityGroup]; ok {
|
||||||
|
logrus.Warn("to use an existing security-group, set `network.external` and `network.name` in your compose file")
|
||||||
logrus.Debugf("Security Group for network %q set by user to %q", net.Name, sg)
|
logrus.Debugf("Security Group for network %q set by user to %q", net.Name, sg)
|
||||||
return sg.(string)
|
return sg.(string)
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user