spark: add verify_structure.sh artifact validation script
This commit is contained in:
1 parent
cf17d9ee0a
commit
c21bae90bd
1 file changed
+33
Executable
+33
@@ -0,0 +1,33 @@
|
||||
#!/bin/bash
|
||||
# Verification script: checks that the artifact directory structure exists and has correct permissions
|
||||
|
||||
set -e
|
||||
|
||||
REQUIRED_DIR="/root/.hermes/wizard-outputs/spark"
|
||||
REQUIRED_FILE="$REQUIRED_DIR/verify_structure.sh"
|
||||
MARKER="$REQUIRED_DIR/.verifier_passed"
|
||||
|
||||
# Check directory exists
|
||||
if [ ! -d "$REQUIRED_DIR" ]; then
|
||||
echo "FAIL: Directory $REQUIRED_DIR does not exist"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Check this script exists (we're running from it)
|
||||
if [ ! -f "$REQUIRED_FILE" ]; then
|
||||
echo "FAIL: Script file missing"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Create marker file to prove success
|
||||
touch "$MARKER"
|
||||
|
||||
if [ -f "$MARKER" ]; then
|
||||
echo "SUCCESS: Artifact structure verified"
|
||||
echo "Directory: $REQUIRED_DIR"
|
||||
echo "Marker: $MARKER"
|
||||
exit 0
|
||||
else
|
||||
echo "FAIL: Could not create marker"
|
||||
exit 1
|
||||
fi
|
||||
Reference in new issue
Block a user