fix(container-create): patch dns (#3556)

pull/3557/head
William 2020-02-12 03:23:56 +13:00 committed by GitHub
parent 97a0ea4a31
commit 0330b16776
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 7 additions and 3 deletions

View File

@ -398,8 +398,12 @@ function ($q, $scope, $async, $state, $timeout, $transition$, $filter, Container
}
$scope.formValues.MacAddress = d.Config.MacAddress;
if (d.HostConfig.Dns && d.HostConfig.Dns[0]) {
$scope.formValues.DnsPrimary = d.HostConfig.Dns[0];
if (d.HostConfig.Dns[1]) {
$scope.formValues.DnsSecondary = d.HostConfig.Dns[1];
}
}
// ExtraHosts
if ($scope.config.HostConfig.ExtraHosts) {