feat: implement license platform business flows and delivery tooling
Add admin and customer interfaces, orders, signed activation and leases, protected package delivery, keyring verification, migrations, security controls, tests and deployment documentation. Co-Authored-By: Craft Agent <agents-noreply@craft.do>
This commit is contained in:
18
scripts/check-delivery.sh
Normal file
18
scripts/check-delivery.sh
Normal file
@@ -0,0 +1,18 @@
|
||||
#!/bin/sh
|
||||
set -eu
|
||||
expected=1
|
||||
for file in backend/migrations/*.up.sql; do
|
||||
[ -s "$file" ] || { echo 'empty migration' >&2; exit 1; }
|
||||
base=${file%.up.sql}
|
||||
[ -s "$base.down.sql" ] || { echo 'missing down migration' >&2; exit 1; }
|
||||
name=${base##*/}
|
||||
version=${name%%_*}
|
||||
[ "$version" = "$(printf '%06d' "$expected")" ] || { echo 'migration sequence must be contiguous and unique' >&2; exit 1; }
|
||||
expected=$((expected + 1))
|
||||
done
|
||||
[ "$expected" -gt 1 ] || { echo 'no migrations found' >&2; exit 1; }
|
||||
for file in backend/migrations/*.down.sql; do
|
||||
[ -s "${file%.down.sql}.up.sql" ] || { echo 'missing up migration' >&2; exit 1; }
|
||||
done
|
||||
for file in scripts/*.sh deploy/entrypoint.sh; do sh -n "$file"; done
|
||||
printf '%s\n' 'Migration naming/pairs and shell syntax passed; this does not execute migrations or Compose.'
|
||||
Reference in New Issue
Block a user