mirror of
https://github.com/GrapheneOS/infrastructure.git
synced 2025-11-21 23:40:33 -05:00
rotate-session-ticket-keys: skip when synced
This commit is contained in:
parent
17f0ec527d
commit
81147f1fbb
1 changed files with 9 additions and 0 deletions
|
|
@ -4,6 +4,15 @@ set -o errexit -o nounset -o pipefail
|
||||||
|
|
||||||
cd /etc/session-ticket-keys
|
cd /etc/session-ticket-keys
|
||||||
|
|
||||||
|
exec {fd}>sync-lock
|
||||||
|
flock $fd
|
||||||
|
|
||||||
|
if [[ -f synced ]]; then
|
||||||
|
echo skipping rotation due to sync
|
||||||
|
rm synced
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
rsync -tI 2.key 1.key
|
rsync -tI 2.key 1.key
|
||||||
rsync -tI 3.key 2.key
|
rsync -tI 3.key 2.key
|
||||||
rsync -tI 4.key 3.key
|
rsync -tI 4.key 3.key
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue