fix(service-creation) - issue with bind mount (#882)

pull/521/head^2
Thomas Krzero 2017-05-25 11:13:29 +02:00 committed by Anthony Lapenna
parent de2818de4c
commit 949f14b119
1 changed files with 1 additions and 6 deletions

View File

@ -176,12 +176,7 @@ function ($scope, $state, Service, ServiceHelper, Volume, Network, ImageHelper,
function prepareVolumes(config, input) {
input.Volumes.forEach(function (volume) {
if (volume.Source && volume.Target) {
var mount = {};
mount.Type = volume.Bind ? 'bind' : 'volume';
mount.ReadOnly = volume.ReadOnly ? true : false;
mount.Source = volume.Source;
mount.Target = volume.Target;
config.TaskTemplate.ContainerSpec.Mounts.push(mount);
config.TaskTemplate.ContainerSpec.Mounts.push(volume);
}
});
}