Skip to content

Commit e0916df

Browse files
authored
Merge pull request #6517 from nextcloud/enh/6408/re-enable-the-update-app
nextcloud: re-enable the updatenotification app
2 parents a84cae7 + 5bbfbed commit e0916df

File tree

3 files changed

+10
-22
lines changed

3 files changed

+10
-22
lines changed

Containers/nextcloud/Dockerfile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -256,7 +256,6 @@ RUN set -ex; \
256256
chmod 777 -R /usr/local/etc/php/conf.d && \
257257
chmod 777 -R /usr/local/etc/php-fpm.d && \
258258
chmod -R 777 /tmp; \
259-
rm -rf /usr/src/nextcloud/apps/updatenotification; \
260259
\
261260
mkdir -p /nc-updater; \
262261
chmod -R 777 /nc-updater

Containers/nextcloud/entrypoint.sh

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -193,14 +193,6 @@ if ! [ -f "$NEXTCLOUD_DATA_DIR/skip.update" ]; then
193193
php /var/www/html/occ app:update --all
194194

195195
run_upgrade_if_needed_due_to_app_update
196-
197-
# Fix removing the updatenotification for old instances
198-
UPDATENOTIFICATION_STATUS="$(php /var/www/html/occ config:app:get updatenotification enabled)"
199-
if [ -d "/var/www/html/apps/updatenotification" ]; then
200-
php /var/www/html/occ app:disable updatenotification
201-
elif [ "$UPDATENOTIFICATION_STATUS" != "no" ] && [ -n "$UPDATENOTIFICATION_STATUS" ]; then
202-
php /var/www/html/occ config:app:set updatenotification enabled --value="no"
203-
fi
204196
fi
205197

206198
echo "Initializing nextcloud $image_version ..."
@@ -277,6 +269,10 @@ DATADIR_PERMISSION_CONF
277269
# unset admin password
278270
unset ADMIN_PASSWORD
279271

272+
# Enable the updatenotification app but disable its UI and server update notifications
273+
php /var/www/html/occ config:system:set updatechecker --type=bool --value=false
274+
php /var/www/html/occ config:app:set updatenotification notify_groups --value="[]"
275+
280276
# AIO update to latest start # Do not remove or change this line!
281277
if [ "$INSTALL_LATEST_MAJOR" = yes ]; then
282278
php /var/www/html/occ config:system:set updatedirectory --value="/nc-updater"
@@ -307,8 +303,7 @@ DATADIR_PERMISSION_CONF
307303
# shellcheck disable=SC2016
308304
installed_version="$(php -r 'require "/var/www/html/version.php"; echo implode(".", $OC_Version);')"
309305
fi
310-
php /var/www/html/occ app:disable updatenotification
311-
rm -rf /var/www/html/apps/updatenotification
306+
php /var/www/html/occ config:system:set updatechecker --type=bool --value=true
312307
php /var/www/html/occ app:enable nextcloud-aio --force
313308
php /var/www/html/occ db:add-missing-columns
314309
php /var/www/html/occ db:add-missing-primary-keys
@@ -354,8 +349,6 @@ DATADIR_PERMISSION_CONF
354349
php /var/www/html/occ config:system:set activity_expire_days --value="30" --type=integer
355350
php /var/www/html/occ config:system:set simpleSignUpLink.shown --type=bool --value=false
356351
php /var/www/html/occ config:system:set share_folder --value="/Shared"
357-
# Not needed anymore with the removal of the updatenotification app:
358-
# php /var/www/html/occ config:app:set updatenotification notify_groups --value="[]"
359352

360353
# Install some apps by default
361354
if [ -n "$STARTUP_APPS" ]; then
@@ -434,6 +427,11 @@ DATADIR_PERMISSION_CONF
434427

435428
run_upgrade_if_needed_due_to_app_update
436429

430+
# Enable the updatenotification app but disable its UI and server update notifications
431+
php /var/www/html/occ config:system:set updatechecker --type=bool --value=false
432+
php /var/www/html/occ app:enable updatenotification
433+
php /var/www/html/occ config:app:set updatenotification notify_groups --value="[]"
434+
437435
# Apply optimization
438436
echo "Doing some optimizations..."
439437
if [ "$NEXTCLOUD_SKIP_DATABASE_OPTIMIZATION" != yes ]; then

app/appinfo/info.xml

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -20,13 +20,4 @@
2020
<admin>OCA\AllInOne\Settings\Admin</admin>
2121
</settings>
2222

23-
<!-- not implemented yet - but might be useful:
24-
<background-jobs>
25-
<job>OCA\AllInOne\Notification\BackgroundJob</job>
26-
</background-jobs>
27-
<commands>
28-
<command>OCA\UpdateNotification\Command\Check</command>
29-
</commands>
30-
-->
31-
3223
</info>

0 commit comments

Comments
 (0)