- 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.
37 lines
1.0 KiB
Bash
Executable File
37 lines
1.0 KiB
Bash
Executable File
#!/usr/bin/env bash
|
|
# Environment configuration loader
|
|
# Usage: source "$SCRIPT_DIR/lib/config/env.sh"
|
|
|
|
# Source paths if not already sourced
|
|
[ -z "${PROJECT_ROOT:-}" ] && source "$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)/../common/paths.sh"
|
|
|
|
# Default subscription ID
|
|
DEFAULT_SUBSCRIPTION_ID="${DEFAULT_SUBSCRIPTION_ID:-fc08d829-4f14-413d-ab27-ce024425db0b}"
|
|
|
|
# Load environment variables from .env file
|
|
load_env() {
|
|
local env_file="${1:-${PROJECT_ROOT}/.env}"
|
|
|
|
if [ -f "$env_file" ]; then
|
|
# Export variables, ignoring comments and empty lines
|
|
set -a
|
|
source <(grep -v '^#' "$env_file" | grep -v '^$' | sed 's/^/export /')
|
|
set +a
|
|
fi
|
|
}
|
|
|
|
# Get Azure subscription ID
|
|
get_subscription_id() {
|
|
echo "${AZURE_SUBSCRIPTION_ID:-${DEFAULT_SUBSCRIPTION_ID}}"
|
|
}
|
|
|
|
# Set Azure subscription
|
|
set_subscription() {
|
|
local subscription_id="${1:-$(get_subscription_id)}"
|
|
az account set --subscription "$subscription_id" &> /dev/null || return 1
|
|
}
|
|
|
|
# Auto-load env if PROJECT_ROOT is set
|
|
[ -n "${PROJECT_ROOT:-}" ] && load_env
|
|
|