Closed sigilworks closed 2 years ago
The buildNetworks function in the latest release of dockerode-compose (v1.3.1) is broken.
buildNetworks
dockerode-compose
It seems there was a refactoring in commit dea731526da26549562c242a8724692eb7a89144 back in May 2021 that broke buildNetworks in serviceTools.js.
dea731526da26549562c242a8724692eb7a89144
In the first conditional (if serviceNetworks is an array):
serviceNetworks
projectName
serviceName
opts
So calling Compose#up on a docker-compose.yml that has services with networks defined causes the operation to fail, when it gets to services.js line 168.
Compose#up
docker-compose.yml
Fixed on https://github.com/apocas/dockerode-compose/pull/22
The
buildNetworks
function in the latest release ofdockerode-compose
(v1.3.1) is broken.It seems there was a refactoring in commit
dea731526da26549562c242a8724692eb7a89144
back in May 2021 that brokebuildNetworks
in serviceTools.js.In the first conditional (if
serviceNetworks
is an array):projectName
is not available/in scope anymore in this new location at line 416serviceName
on line 425opts
object at line 427So calling
Compose#up
on adocker-compose.yml
that has services with networks defined causes the operation to fail, when it gets to services.js line 168.