mirror of https://github.com/portainer/portainer
parent
082cf5772b
commit
f28f223624
|
@ -7,6 +7,7 @@ function TemplateViewModel(data) {
|
|||
this.Command = data.command ? data.command : '';
|
||||
this.Network = data.network ? data.network : '';
|
||||
this.Env = data.env ? data.env : [];
|
||||
this.Privileged = data.privileged ? data.privileged : false;
|
||||
this.Volumes = [];
|
||||
if (data.volumes) {
|
||||
this.Volumes = data.volumes.map(function (v) {
|
||||
|
|
|
@ -37,6 +37,7 @@ angular.module('portainer.services')
|
|||
service.createContainerConfiguration = function(template, containerName, network, containerMapping) {
|
||||
var configuration = TemplateHelper.getDefaultContainerConfiguration();
|
||||
configuration.HostConfig.NetworkMode = network.Name;
|
||||
configuration.HostConfig.Privileged = template.Privileged;
|
||||
configuration.name = containerName;
|
||||
configuration.Image = template.Image;
|
||||
configuration.Env = TemplateHelper.EnvToStringArray(template.Env, containerMapping);
|
||||
|
|
Loading…
Reference in New Issue