mirror of
https://github.com/docker/compose.git
synced 2026-07-01 21:54:30 +00:00
only expose API socket to service asking for it
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
This commit is contained in:
parent
3394bf031b
commit
6514c680a5
1 changed files with 3 additions and 0 deletions
|
|
@ -64,6 +64,9 @@ func (s *composeService) useAPISocket(project *types.Project) (*types.Project, e
|
|||
}
|
||||
|
||||
for name, service := range project.Services {
|
||||
if !service.UseAPISocket {
|
||||
continue
|
||||
}
|
||||
service.Volumes = append(service.Volumes, types.ServiceVolumeConfig{
|
||||
Type: types.VolumeTypeBind,
|
||||
Source: socket,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue