fix packaging ownership for Unraid
This commit is contained in:
@@ -0,0 +1,3 @@
|
||||
.DS_Store
|
||||
._*
|
||||
.plugin-build/
|
||||
+12
-1
@@ -1,6 +1,9 @@
|
||||
#!/bin/sh
|
||||
set -eu
|
||||
|
||||
# Keine macOS-Metadaten oder lokale UID 501 in das Unraid-Paket übernehmen.
|
||||
export COPYFILE_DISABLE=1
|
||||
|
||||
PLUGIN="u-navigator"
|
||||
VERSION="2026.07.14.r017"
|
||||
PKG_DIR="packages"
|
||||
@@ -15,7 +18,15 @@ cp server/public/app.js "$WORK_DIR/usr/local/emhttp/plugins/${PLUGIN}/assets/app
|
||||
cp server/public/styles.css "$WORK_DIR/usr/local/emhttp/plugins/${PLUGIN}/assets/styles.css"
|
||||
perl -0pi -e "s/__VERSION__/${VERSION}/g" "$WORK_DIR/usr/local/emhttp/plugins/${PLUGIN}/U-Navigator.page"
|
||||
|
||||
tar -czf "$PKG_DIR/$PKG_NAME" -C "$WORK_DIR" usr
|
||||
find "$WORK_DIR" -name '._*' -delete
|
||||
if tar --version 2>/dev/null | grep -q 'GNU tar'; then
|
||||
TAR_OWNER_FLAGS="--owner=0 --group=0 --numeric-owner"
|
||||
else
|
||||
TAR_OWNER_FLAGS="--uid 0 --gid 0 --uname root --gname root"
|
||||
fi
|
||||
# Die Argumente sind feste, intern definierte tar-Flags.
|
||||
# shellcheck disable=SC2086
|
||||
tar --no-xattrs $TAR_OWNER_FLAGS -czf "$PKG_DIR/$PKG_NAME" -C "$WORK_DIR" usr
|
||||
rm -rf "$WORK_DIR"
|
||||
|
||||
MD5="$(md5 -q "$PKG_DIR/$PKG_NAME" 2>/dev/null || md5sum "$PKG_DIR/$PKG_NAME" | awk '{print $1}')"
|
||||
|
||||
Binary file not shown.
+1
-1
@@ -24,7 +24,7 @@
|
||||
|
||||
<FILE Name="/boot/config/plugins/&name;/&package;">
|
||||
<URL>https://git.casaderoll.de/michael/Unraid-Navigator/raw/branch/main/packages/&package;</URL>
|
||||
<MD5>3fa2ea5659712c219ce073b7a16410c5</MD5>
|
||||
<MD5>571b9c735dfab01e7d62736bf517dc45</MD5>
|
||||
</FILE>
|
||||
|
||||
<FILE Run="/bin/bash">
|
||||
|
||||
Reference in New Issue
Block a user