[28207] in Source-Commits
auto-update commit: Move update hook location and clean-up on success
daemon@ATHENA.MIT.EDU (Jonathan D Reed)
Tue May 13 15:43:46 2014
Date: Tue, 13 May 2014 15:43:38 -0400
From: Jonathan D Reed <jdreed@MIT.EDU>
Message-Id: <201405131943.s4DJhcu8025360@drugstore.mit.edu>
To: source-commits@MIT.EDU
https://github.com/mit-athena/auto-update/commit/40ffb03f155dfd3db1b5ed31bd92b27486c2bdfb
commit 40ffb03f155dfd3db1b5ed31bd92b27486c2bdfb
Author: Jonathan Reed <jdreed@mit.edu>
Date: Tue May 13 15:32:45 2014 -0400
Move update hook location and clean-up on success
/run is noexec, so we can't actually execute the update hook, so
we move it to /var/tmp instead (Trac: #1461)
We also clean up the hook upon successful execution
debian/athena-auto-update | 3 ++-
debian/changelog | 8 ++++++++
2 files changed, 10 insertions(+), 1 deletions(-)
diff --git a/debian/athena-auto-update b/debian/athena-auto-update
index ac9ae69..6f2e35e 100644
--- a/debian/athena-auto-update
+++ b/debian/athena-auto-update
@@ -185,7 +185,7 @@ fi
UPDATE_HOOK_URL="https://athena10.mit.edu/update-hook/debathena-update-hook.sh"
UPDATE_HOOK_SUM="https://athena10.mit.edu/update-hook/debathena-update-hook-sha256sum"
MITCA="/usr/share/debathena-auto-update/mitCA.crt"
-UPDATE_HOOK="/var/run/debathena-update-hook.sh"
+UPDATE_HOOK="/var/tmp/debathena-update-hook.sh"
rm -f $UPDATE_HOOK
if [ "$RUN_UPDATE_HOOK" = "yes" ] && \
@@ -208,6 +208,7 @@ if [ "$RUN_UPDATE_HOOK" = "yes" ] && \
exit
else
touch "/var/lib/athena-update-hooks/$SHA256SUM"
+ rm -f $UPDATE_HOOK
fi
fi
fi
diff --git a/debian/changelog b/debian/changelog
index 3fd45ac..59bbbd4 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,11 @@
+debathena-auto-update (1.45) unstable; urgency=low
+
+ * Do not attempt to run update hooks out of /var/run, since it's mounted
+ noexec; use /var/tmp instead (Trac: #1461)
+ * Delete the script upon successful execution
+
+ -- Jonathan Reed <jdreed@mit.edu> Tue, 13 May 2014 15:32:36 -0400
+
debathena-auto-update (1.44) unstable; urgency=low
* Add git-buildpackage configuration