Files
smom-dbis-138/scripts/automation/validate-configs.sh
defiQUG 1fb7266469 Add Oracle Aggregator and CCIP Integration
- Introduced Aggregator.sol for Chainlink-compatible oracle functionality, including round-based updates and access control.
- Added OracleWithCCIP.sol to extend Aggregator with CCIP cross-chain messaging capabilities.
- Created .gitmodules to include OpenZeppelin contracts as a submodule.
- Developed a comprehensive deployment guide in NEXT_STEPS_COMPLETE_GUIDE.md for Phase 2 and smart contract deployment.
- Implemented Vite configuration for the orchestration portal, supporting both Vue and React frameworks.
- Added server-side logic for the Multi-Cloud Orchestration Portal, including API endpoints for environment management and monitoring.
- Created scripts for resource import and usage validation across non-US regions.
- Added tests for CCIP error handling and integration to ensure robust functionality.
- Included various new files and directories for the orchestration portal and deployment scripts.
2025-12-12 14:57:48 -08:00

51 lines
1.3 KiB
Bash
Executable File

#!/usr/bin/env bash
# Validate all configuration files
# Checks JSON, YAML, and TOML files for validity
set -euo pipefail
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
PROJECT_ROOT="$(cd "$SCRIPT_DIR/../.." && pwd)"
source "$SCRIPT_DIR/../lib/init.sh"
source "$SCRIPT_DIR/../lib/common/validation.sh"
cd "$PROJECT_ROOT"
log_section "Configuration Validation"
errors=0
# Validate JSON files
log_subsection "Validating JSON files"
while IFS= read -r -d '' file; do
if ! validate_json "$file"; then
((errors++)) || true
fi
done < <(find config -name "*.json" -type f -print0 2>/dev/null)
# Validate YAML files
log_subsection "Validating YAML files"
while IFS= read -r -d '' file; do
if ! validate_yaml "$file"; then
((errors++)) || true
fi
done < <(find . -name "*.yml" -o -name "*.yaml" -type f -print0 2>/dev/null | grep -v node_modules | grep -v .terraform)
# Validate TOML files
log_subsection "Validating TOML files"
while IFS= read -r -d '' file; do
if ! validate_toml "$file"; then
((errors++)) || true
fi
done < <(find config -name "*.toml" -type f -print0 2>/dev/null)
if [ $errors -eq 0 ]; then
log_success "All configuration files are valid"
exit 0
else
log_error "Found $errors configuration file errors"
exit 1
fi