#!/usr/bin/env bash
set -euo pipefail
destination="/srv/ldw/backups/$(date -u +%Y%m%dT%H%M%SZ)"
install -d -m 0700 "$destination"
tar --exclude='*/releases/*' -C /srv/ldw -czf "$destination/ldw-state.tar.gz" projects
sha256sum "$destination/ldw-state.tar.gz" >"$destination/SHA256SUMS"
