1
0
Fork 0
mirror of https://github.com/portainer/portainer.git synced 2025-07-21 14:29:40 +02:00

feat(container-details): update re-creation flow (#2193)

This commit is contained in:
Anthony Lapenna 2018-08-20 20:55:12 +02:00 committed by GitHub
parent 1b51daf9c4
commit 64beaaa279
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 8 deletions

View file

@ -196,9 +196,9 @@ function ($q, $scope, $state, $transition$, $filter, Commit, ContainerHelper, Co
$scope.state.recreateContainerInProgress = true;
var isRunning = container.State.Running;
return stopContainerIfNeeded()
return pullImageIfNeeded()
.then(stopContainerIfNeeded)
.then(renameContainer)
.then(pullImageIfNeeded)
.then(setMainNetworkAndCreateContainer)
.then(connectContainerToOtherNetworks)
.then(startContainerIfNeeded)
@ -312,7 +312,7 @@ function ($q, $scope, $state, $transition$, $filter, Commit, ContainerHelper, Co
function updateRestartPolicy(restartPolicy, maximumRetryCount) {
maximumRetryCount = restartPolicy === 'on-failure' ? maximumRetryCount : undefined;
return ContainerService
.updateRestartPolicy($scope.container.Id, restartPolicy, maximumRetryCount)
.then(onUpdateSuccess)