-
-
Notifications
You must be signed in to change notification settings - Fork 4.6k
feat(updater): Allow to define locked apps to (not) be updated #55113
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
ee3b61a to
6c81571
Compare
6c81571 to
7cdf800
Compare
Signed-off-by: Git'Fellow <[email protected]>
7cdf800 to
3040762
Compare
|
This is missing documentation in config.sample.php |
|
I'll do it when green light about a possible merge 😁 |
|
@AndyScherzinger what do you think about this feature :) |
|
I'd like to discuss it first, since I get the use case and motivation but think the feature solves an issue that shouldn't be there in the first place: there shouldn't be a reason not to update an app Things I do understand in terms of version management and would agree to are:
Or in other word admins shouldn't need a a mechanism to block updating for some apps since they should be the only ones having the permissions on the system to do it anyways (!). |
|
Main problems I'm trying to solve here are:
Sometimes, there is a good reason. |
|
Once again here: nextcloud/groupfolders#4003 |
|
Btw we already have support for multiple app directories and having them marked read-only, however a lot of the logic around it is really broken and would be fixed by #51667 |
Another idea is to generally not update apps with Nextcloud, unless required for compatibility. But means more efforts for admins to update everything. |
Summary
In some environnements, it can be useful to "lock" apps to disallow updates by administrators for many reasons; control when updates are made, deny updates from the Web while manually forcing them on the CLI (after disable the switch), forcing an app to remain on a specific version, etc.
Actually, to accomplish a similar behavior, one must render the
/apps/<app>folder unwritable by the webserver (ex.:cd /var/www/nextcloud/apps/; chmod 0750 <app>; chown -R root:www-data <app>) because if webserver can't write on the app folder, app can't be updated.With this PR, an Administrator could publish an array of apps on
config.phplike:'apps_locked' => ['user_saml', 'groupfolders', 'onlyoffice'];And such apps couldn't be updated unless the app name is removed from the array.
We could also implement a
--forceswitch on the CLI, but i believe that removing the app from the array could be more effective.One question remains; if, while upgrading server to a major version (32>33) apps need update for compatibility reasons, how to handle this case effectively:
Please review and comment.
ToDo
Checklist