mirror of https://github.com/portainer/portainer
fix(container-creation): ignore error when pulling an image (#914)
parent
1c4ccfe294
commit
d5f00597a5
|
@ -299,10 +299,9 @@ function ($q, $scope, $state, $stateParams, $filter, Info, Container, ContainerH
|
|||
};
|
||||
|
||||
function createContainer(config, accessControlData) {
|
||||
$q.when($scope.formValues.alwaysPull ? ImageService.pullImage($scope.config.Image, $scope.formValues.Registry) : null)
|
||||
.then(function success() {
|
||||
return ContainerService.createAndStartContainer(config);
|
||||
})
|
||||
$q.when(!$scope.formValues.alwaysPull || ImageService.pullImage($scope.config.Image, $scope.formValues.Registry))
|
||||
.finally(function final() {
|
||||
ContainerService.createAndStartContainer(config)
|
||||
.then(function success(data) {
|
||||
var containerIdentifier = data.Id;
|
||||
var userId = Authentication.getUserDetails().ID;
|
||||
|
@ -318,6 +317,7 @@ function ($q, $scope, $state, $stateParams, $filter, Info, Container, ContainerH
|
|||
.finally(function final() {
|
||||
$('#createContainerSpinner').hide();
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
initView();
|
||||
|
|
Loading…
Reference in New Issue