1
0
Fork 0
mirror of https://github.com/portainer/portainer.git synced 2025-07-25 08:19:40 +02:00

fix(stack): git stack redeploy issue EE-2737 (#6667)

* fix(stack) git stack redeploy issue
This commit is contained in:
sunportainer 2022-03-28 21:31:03 +08:00 committed by GitHub
parent 379f9e2822
commit b846c8e6d2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -95,13 +95,13 @@ class StackRedeployGitFormController {
'<be-feature-indicator feature="stackPullImageFeature"></be-feature-indicator></div></div>';
const template = angular.element(tplCrop);
const html = this.$compile(template)(this.$scope);
this.ModalService.confirmStackUpdate(html, true, true, 'btn-warning', function (result) {
this.ModalService.confirmStackUpdate(html, true, true, 'btn-warning', async (result) => {
if (!result) {
return;
}
try {
this.state.redeployInProgress = true;
this.StackService.updateGit(this.stack.Id, this.stack.EndpointId, this.FormHelper.removeInvalidEnvVars(this.formValues.Env), false, this.formValues);
await this.StackService.updateGit(this.stack.Id, this.stack.EndpointId, this.FormHelper.removeInvalidEnvVars(this.formValues.Env), false, this.formValues);
this.Notifications.success('Pulled and redeployed stack successfully');
this.$state.reload();
} catch (err) {