mirror of
https://github.com/portainer/portainer.git
synced 2025-07-22 23:09:41 +02:00
fix(container): prevent user from editing the portainer container it self EE-917 (#6093)
* fix(container): prevent from editing portainer container * fix(container): prevent from editing portainer container * Missing kill operation * fix(container): enhance creating stack from template * fix(docker): prevent user from editing the portainer container itself EE-917 * fix(docker): enhance code style * fix(container): fix issues from code review * fix(container): enhance creating stack from template * fix(container): some code review issues * fix(container): disable leave network when the container is portainer * fix(container): disable leave network when the container is portainer
This commit is contained in:
parent
d2fe76368a
commit
42e782452c
9 changed files with 74 additions and 13 deletions
|
@ -69,6 +69,11 @@ func (transport *Transport) containerListOperation(response *http.Response, exec
|
|||
}
|
||||
}
|
||||
|
||||
responseArray, err = transport.applyPortainerContainers(responseArray)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
return utils.RewriteResponse(response, responseArray, http.StatusOK)
|
||||
}
|
||||
|
||||
|
@ -88,6 +93,8 @@ func (transport *Transport) containerInspectOperation(response *http.Response, e
|
|||
labelsObjectSelector: selectorContainerLabelsFromContainerInspectOperation,
|
||||
}
|
||||
|
||||
responseObject, _ = transport.applyPortainerContainer(responseObject)
|
||||
|
||||
return transport.applyAccessControlOnResource(resourceOperationParameters, responseObject, response, executor)
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue