Let sandboxed agents use mktemp, and keep backups from waiting on prompts

macOS' mktemp uses the per-user temp folder in /var/folders, not TMPDIR,
so the sandbox now allows writing there. The sandbox's settings move out
of it, to Application Support, which the agent can't read or write.

Without Full Disk Access, reading Desktop, Documents, Downloads, other
apps' containers or Photos makes macOS ask, and restic waited for an
answer no one gives at night. The backup now leaves those out until it
has Full Disk Access, as configure backup already said it did.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
David Young
2026-11-11 16:19:21 -07:00
co-authored by Claude Opus 5.5
parent eab26c0888
commit ad97e68db1
4 changed files with 36 additions and 9 deletions
+2 -1
View File
@@ -4,7 +4,8 @@ TIER=quick
source "$CONNECTOR/configure.d/20-backup.sh"
DAV="$HOME/davroot"
SMOKE_FILE="$HOME/Documents/smoke-file.txt"
# Outside Documents, which a backup without Full Disk Access leaves out
SMOKE_FILE="$HOME/Projects/smoke-file.txt"
ran() {
grep -qE 'Backup (finished|failed)' "$BACKUP_LOG" 2> /dev/null