mirror of https://github.com/docker/cli.git
Update ConvertService for external usage 👼
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
This commit is contained in:
parent
583ed2e3be
commit
96dc07a8cf
|
@ -41,7 +41,7 @@ func Services(
|
||||||
return nil, errors.Wrapf(err, "service %s", service.Name)
|
return nil, errors.Wrapf(err, "service %s", service.Name)
|
||||||
}
|
}
|
||||||
|
|
||||||
serviceSpec, err := convertService(client.ClientVersion(), namespace, service, networks, volumes, secrets, configs)
|
serviceSpec, err := Service(client.ClientVersion(), namespace, service, networks, volumes, secrets, configs)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, errors.Wrapf(err, "service %s", service.Name)
|
return nil, errors.Wrapf(err, "service %s", service.Name)
|
||||||
}
|
}
|
||||||
|
@ -51,7 +51,8 @@ func Services(
|
||||||
return result, nil
|
return result, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func convertService(
|
// Service converts a ServiceConfig into a swarm ServiceSpec
|
||||||
|
func Service(
|
||||||
apiVersion string,
|
apiVersion string,
|
||||||
namespace Namespace,
|
namespace Namespace,
|
||||||
service composetypes.ServiceConfig,
|
service composetypes.ServiceConfig,
|
||||||
|
|
Loading…
Reference in New Issue