mirror of
https://github.com/nextcloud/nextcloudpi.git
synced 2026-01-09 14:42:01 -03:30
nc-init.sh, ncp-update-nc, library.sh: Fix invalid architecture name in notify_push binary path
Signed-off-by: thecalcaholic <6317548+theCalcaholic@users.noreply.github.com>
This commit is contained in:
parent
c41d38aa2a
commit
c619589a22
@ -194,8 +194,6 @@ else
|
|||||||
apachectl -k graceful
|
apachectl -k graceful
|
||||||
## make sure the notify_push daemon is runnnig
|
## make sure the notify_push daemon is runnnig
|
||||||
|
|
||||||
arch="$(dpkg --print-architecture)"
|
|
||||||
[[ "${arch}" =~ ^(armhf|arm)$ ]] && arch="armv7"
|
|
||||||
cat > /etc/systemd/system/notify_push.service <<EOF
|
cat > /etc/systemd/system/notify_push.service <<EOF
|
||||||
[Unit]
|
[Unit]
|
||||||
Description = Push daemon for Nextcloud clients
|
Description = Push daemon for Nextcloud clients
|
||||||
@ -206,7 +204,7 @@ Requires=redis.service
|
|||||||
[Service]
|
[Service]
|
||||||
Environment=PORT=7867
|
Environment=PORT=7867
|
||||||
Environment=NEXTCLOUD_URL=https://localhost
|
Environment=NEXTCLOUD_URL=https://localhost
|
||||||
ExecStart=/var/www/nextcloud/apps/notify_push/bin/"${arch}"/notify_push --allow-self-signed /var/www/nextcloud/config/config.php
|
ExecStart="/var/www/nextcloud/apps/notify_push/bin/${ARCH}/notify_push" --allow-self-signed /var/www/nextcloud/config/config.php
|
||||||
User=www-data
|
User=www-data
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
|
|||||||
@ -152,7 +152,7 @@ EOF
|
|||||||
ncc app:disable updatenotification
|
ncc app:disable updatenotification
|
||||||
|
|
||||||
# News dropped support for 32-bit -> https://github.com/nextcloud/news/issues/1423
|
# News dropped support for 32-bit -> https://github.com/nextcloud/news/issues/1423
|
||||||
if ! [[ "$(dpkg --print-architecture)" =~ ^(armhf|arm)$ ]]; then
|
if ! [[ "$ARCH" =~ armv7 ]]; then
|
||||||
ncc app:install news
|
ncc app:install news
|
||||||
ncc app:enable news
|
ncc app:enable news
|
||||||
fi
|
fi
|
||||||
|
|||||||
@ -13,6 +13,10 @@ export BINDIR=/usr/local/bin/ncp
|
|||||||
export NCDIR=/var/www/nextcloud
|
export NCDIR=/var/www/nextcloud
|
||||||
export ncc=/usr/local/bin/ncc
|
export ncc=/usr/local/bin/ncc
|
||||||
export NCPCFG=${NCPCFG:-etc/ncp.cfg}
|
export NCPCFG=${NCPCFG:-etc/ncp.cfg}
|
||||||
|
export ARCH="$(dpkg --print-architecture)"
|
||||||
|
[[ "${ARCH}" =~ ^(armhf|arm)$ ]] && ARCH="armv7"
|
||||||
|
[[ "${ARCH}" == "arm64" ]] && ARCH=aarch64
|
||||||
|
[[ "${ARCH}" == "amd64" ]] && ARCH=x86_64
|
||||||
# Prevent systemd pager from blocking script execution
|
# Prevent systemd pager from blocking script execution
|
||||||
export SYSTEMD_PAGER=
|
export SYSTEMD_PAGER=
|
||||||
|
|
||||||
@ -163,10 +167,7 @@ function start_notify_push
|
|||||||
{
|
{
|
||||||
pgrep notify_push &>/dev/null && return
|
pgrep notify_push &>/dev/null && return
|
||||||
if [[ -f /.docker-image ]]; then
|
if [[ -f /.docker-image ]]; then
|
||||||
local arch
|
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 &
|
||||||
arch="$(dpkg --print-architecture)"
|
|
||||||
[[ "${arch}" =~ ^(armhf|arm)$ ]] && arch="armv7"
|
|
||||||
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 &
|
|
||||||
else
|
else
|
||||||
systemctl enable --now notify_push
|
systemctl enable --now notify_push
|
||||||
fi
|
fi
|
||||||
|
|||||||
@ -35,8 +35,6 @@ install_app nc-restore
|
|||||||
[[ ! -f /.docker-image ]] && {
|
[[ ! -f /.docker-image ]] && {
|
||||||
|
|
||||||
# fix HPB with dynamic public IP
|
# fix HPB with dynamic public IP
|
||||||
arch="$(dpkg --print-architecture)"
|
|
||||||
[[ "${arch}" =~ ^(armhf|arm)$ ]] && arch="armv7"
|
|
||||||
cat > /etc/systemd/system/notify_push.service <<EOF
|
cat > /etc/systemd/system/notify_push.service <<EOF
|
||||||
[Unit]
|
[Unit]
|
||||||
Description = Push daemon for Nextcloud clients
|
Description = Push daemon for Nextcloud clients
|
||||||
@ -45,7 +43,7 @@ After = mysql.service
|
|||||||
[Service]
|
[Service]
|
||||||
Environment = PORT=7867
|
Environment = PORT=7867
|
||||||
Environment = NEXTCLOUD_URL=https://localhost
|
Environment = NEXTCLOUD_URL=https://localhost
|
||||||
ExecStart = /var/www/nextcloud/apps/notify_push/bin/"${arch}"/notify_push --allow-self-signed /var/www/nextcloud/config/config.php
|
ExecStart = "/var/www/nextcloud/apps/notify_push/bin/${ARCH}/notify_push" --allow-self-signed /var/www/nextcloud/config/config.php
|
||||||
User=www-data
|
User=www-data
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user