File tree Expand file tree Collapse file tree 4 files changed +8
-11
lines changed Expand file tree Collapse file tree 4 files changed +8
-11
lines changed Original file line number Diff line number Diff line change 194194 apachectl -k graceful
195195 # # make sure the notify_push daemon is runnnig
196196
197- arch=" $( dpkg --print-architecture) "
198- [[ " ${arch} " =~ ^(armhf| arm)$ ]] && arch=" armv7"
199197 cat > /etc/systemd/system/notify_push.service << EOF
200198[Unit]
201199Description = Push daemon for Nextcloud clients
@@ -206,7 +204,7 @@ Requires=redis.service
206204[Service]
207205Environment=PORT=7867
208206Environment=NEXTCLOUD_URL=https://localhost
209- ExecStart=/var/www/nextcloud/apps/notify_push/bin/" ${arch} " /notify_push --allow-self-signed /var/www/nextcloud/config/config.php
207+ ExecStart=" /var/www/nextcloud/apps/notify_push/bin/${ARCH} /notify_push" --allow-self-signed /var/www/nextcloud/config/config.php
210208User=www-data
211209
212210[Install]
Original file line number Diff line number Diff line change 152152 ncc app:disable updatenotification
153153
154154 # News dropped support for 32-bit -> https://github.com/nextcloud/news/issues/1423
155- if ! [[ " $( dpkg --print-architecture ) " =~ ^(armhf | arm)$ ]]; then
155+ if ! [[ " $ARCH " =~ armv7 ]]; then
156156 ncc app:install news
157157 ncc app:enable news
158158 fi
Original file line number Diff line number Diff line change @@ -13,6 +13,10 @@ export BINDIR=/usr/local/bin/ncp
1313export NCDIR=/var/www/nextcloud
1414export ncc=/usr/local/bin/ncc
1515export NCPCFG=${NCPCFG:- etc/ ncp.cfg}
16+ export ARCH=" $( dpkg --print-architecture) "
17+ [[ " ${ARCH} " =~ ^(armhf| arm)$ ]] && ARCH=" armv7"
18+ [[ " ${ARCH} " == " arm64" ]] && ARCH=aarch64
19+ [[ " ${ARCH} " == " amd64" ]] && ARCH=x86_64
1620# Prevent systemd pager from blocking script execution
1721export SYSTEMD_PAGER=
1822
@@ -163,10 +167,7 @@ function start_notify_push
163167{
164168 pgrep notify_push & > /dev/null && return
165169 if [[ -f /.docker-image ]]; then
166- local arch
167- arch=" $( dpkg --print-architecture) "
168- [[ " ${arch} " =~ ^(armhf| arm)$ ]] && arch=" armv7"
169- NEXTCLOUD_URL=https://localhost sudo -E -u www-data /var/www/nextcloud/apps/notify_push/bin/" ${arch} " /notify_push --allow-self-signed /var/www/nextcloud/config/config.php & > /dev/null &
170+ NEXTCLOUD_URL=https://localhost sudo -E -u www-data " /var/www/nextcloud/apps/notify_push/bin/${ARCH} /notify_push" --allow-self-signed /var/www/nextcloud/config/config.php & > /dev/null &
170171 else
171172 systemctl enable --now notify_push
172173 fi
Original file line number Diff line number Diff line change @@ -35,8 +35,6 @@ install_app nc-restore
3535[[ ! -f /.docker-image ]] && {
3636
3737 # fix HPB with dynamic public IP
38- arch=" $( dpkg --print-architecture) "
39- [[ " ${arch} " =~ ^(armhf| arm)$ ]] && arch=" armv7"
4038 cat > /etc/systemd/system/notify_push.service << EOF
4139[Unit]
4240Description = Push daemon for Nextcloud clients
@@ -45,7 +43,7 @@ After = mysql.service
4543[Service]
4644Environment = PORT=7867
4745Environment = NEXTCLOUD_URL=https://localhost
48- ExecStart = /var/www/nextcloud/apps/notify_push/bin/" ${arch} " /notify_push --allow-self-signed /var/www/nextcloud/config/config.php
46+ ExecStart = " /var/www/nextcloud/apps/notify_push/bin/${ARCH} /notify_push" --allow-self-signed /var/www/nextcloud/config/config.php
4947User=www-data
5048
5149[Install]
You can’t perform that action at this time.
0 commit comments