Skip to content

Commit

Permalink
add background-worker.sh script for nextcloud
Browse files Browse the repository at this point in the history
  • Loading branch information
lilioid committed Oct 7, 2024
1 parent 54bfb1e commit 3bb035d
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
1 change: 1 addition & 0 deletions nextcloud/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ RUN chown www-data /opt/config

ADD start.sh /usr/local/bin/run
ADD cron.sh /usr/local/bin/cron.sh
ADD background-worker.sh /usr/local/bin/background-worker.sh
VOLUME /opt/storage /opt/config /opt/log /opt/static
EXPOSE 9787/tcp
ENTRYPOINT /usr/local/bin/run
8 changes: 8 additions & 0 deletions nextcloud/background-worker.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#!/bin/sh
set -e
cp /opt/config/config.php /var/www/nextcloud/config/config.php
chown -R www-data /var/www/nextcloud/config /var/www/nextcloud/apps /opt/log
chmod +x /var/www/nextcloud/occ
export USER=www-data HOME=/home/www-data

exec su -s /var/www/nextcloud/occ background-jobs:worker

0 comments on commit 3bb035d

Please sign in to comment.