aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam Scholten2025-10-24 08:56:18 +1000
committerSam Scholten2025-10-24 08:56:18 +1000
commit0f99db5d30bdaadf6cfd8f8e3405a6f35c2398aa (patch)
tree9cfe44c44b950746a51730d4baf7138eee1c87a2
parent04f28e2e6496195e16afdfed26135180b8600993 (diff)
downloaddrestic-0f99db5d30bdaadf6cfd8f8e3405a6f35c2398aa.tar.gz
drestic-0f99db5d30bdaadf6cfd8f8e3405a6f35c2398aa.zip
Fix make config to detect system scope configuration
Add sudo before checking for /root/.restic_env in the config target. Without sudo, the check runs as the regular user and can't see the system scope environment file, causing make config to incorrectly report 'No DRestic configuration found' when system scope is set up.
-rw-r--r--Makefile2
1 files changed, 1 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 636e126..8c3fe81 100644
--- a/Makefile
+++ b/Makefile
@@ -415,7 +415,7 @@ validate-config:
else \
echo "✗ Rclone connection failed"; \
fi; \
- elif [ -f /root/.restic_env ]; then \
+ elif sudo [ -f /root/.restic_env ]; then \
echo "✓ System scope configuration found"; \
echo "Checking system configuration..."; \
if sudo [ -f /root/.restic_password ] && sudo [ -s /root/.restic_password ]; then \