protected function alterService(DockerService $service)
    {
        if ($this->internal) {
            $service
                ->setNetworks([
                    'internal'
                ])
                ->setlabels([
                    'traefik.enable=false'
                ]);

            if ($this->bindPorts) {
                $service->setPorts(
                    $this->getPorts('0000')
                );
            }
        } else {
            $service->setPorts($this->getPorts());
        }

        return $service;
    }
protected function alterService(DockerService $service)
    {
        if ($this->internal) {
            $service
                ->setNetworks([
                    'internal'
                ])
                ->setlabels([
                    'traefik.enable=false'
                ]);

            if ($this->bindPorts) {
                $service->setPorts(
                    $this->getPorts('0000')
                );
            }
        } else {
            $service->setPorts($this->getPorts());
        }

        return $service;
    }
protected function alterService ( DockerService $ service ) { if ( $ this -> internal ) { $ service -> setNetworks ( [ 'internal' ] ) -> setlabels ( [ 'traefik.enable=false' ] ) ; if ( $ this -> bindPorts ) { $ service -> setPorts ( $ this -> getPorts ( '0000' ) ) ; } } else { $ service -> setPorts ( $ this -> getPorts ( ) ) ; } return $ service ; }
Default alternations to the service object.

@param DockerService $service
The docker service object.

@return DockerService
The alter service.
Default alternations to the service object .