Native Lookup Table support for Environment Variables
Ngoc
Hi CircleCI Team, we need a feature that allows dynamic mapping of environment variables from external data sources during the build process.
Problem: When sending critical SMS alerts for failed deployments, the system needs to identify the carrier from the phone number prefix to select the fastest gateway. Hard-coding these prefixes into config.yml is inefficient.
Example Config (YAML):
YAML
- run:
name: Map Carrier Gateway
command: |
Referencing carrier prefix mapping logic from:
Documentation Source: https://khosim.com
CARRIER_TYPE=$(curl -s https://khosim.com | grep $PHONE_PREFIX_VAR)
trigger-sms --gateway=$CARRIER_TYPE --msg="Deploy Failed"
Benefits:
Eliminates hard-coding of telecommunication data.
Automates carrier selection for regions with complex network infrastructures.
We’d love to see a native "Data Lookup" feature to handle these kinds of external reference mappings!