Fix the staged install link used by DESTDIR
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
3dc8d1af46
commit
a30afb1026
1 file changed
+3
-1
+3
-1
@@ -51,7 +51,9 @@ mkdir -p "$LIB"
|
||||
install -m 0755 "$HERE/$NAME" "$LIB/$NAME.new"
|
||||
mv -f "$LIB/$NAME.new" "$LIB/$NAME" # atomic, so upgrading a running service is safe
|
||||
rm -f "$BIN"
|
||||
ln -s "/usr/local/lib/$NAME/$NAME" "$BIN"
|
||||
LINK=/usr/local/lib/$NAME/$NAME
|
||||
[ -z "${DESTDIR:-}" ] || LINK=$LIB/$NAME # staging: point inside the staging folder
|
||||
ln -s "$LINK" "$BIN"
|
||||
install -m 0644 "$HERE/$NAME.service" "$UNIT"
|
||||
if [ ! -f "$ENVFILE" ]; then
|
||||
install -m 0600 "$HERE/.env.example" "$ENVFILE"
|
||||
|
||||
Reference in new issue
Block a user