mirror of
https://github.com/balena-os/balena-supervisor.git
synced 2025-06-01 23:30:48 +00:00
Merge pull request #964 from balena-io/fix-double-expose
compose: Remove unique expose entries after adding all entries
This commit is contained in:
commit
7be1fa3c08
@ -279,12 +279,12 @@ export class Service {
|
|||||||
{},
|
{},
|
||||||
);
|
);
|
||||||
expose = expose.concat(_.keys(imageExposedPorts));
|
expose = expose.concat(_.keys(imageExposedPorts));
|
||||||
expose = _.uniq(expose);
|
|
||||||
// Also add any exposed ports which are implied from the portMaps
|
// Also add any exposed ports which are implied from the portMaps
|
||||||
const exposedFromPortMappings = _.flatMap(portMaps, port =>
|
const exposedFromPortMappings = _.flatMap(portMaps, port =>
|
||||||
port.toExposedPortArray(),
|
port.toExposedPortArray(),
|
||||||
);
|
);
|
||||||
expose = expose.concat(exposedFromPortMappings);
|
expose = expose.concat(exposedFromPortMappings);
|
||||||
|
expose = _.uniq(expose);
|
||||||
delete config.expose;
|
delete config.expose;
|
||||||
|
|
||||||
let devices: DockerDevice[] = [];
|
let devices: DockerDevice[] = [];
|
||||||
|
Loading…
x
Reference in New Issue
Block a user