Skip to content

Instantly share code, notes, and snippets.

@jacobsapps
Created September 12, 2025 18:02
Show Gist options
  • Select an option

  • Save jacobsapps/6c45c62712cd20231ba46b96fce670e5 to your computer and use it in GitHub Desktop.

Select an option

Save jacobsapps/6c45c62712cd20231ba46b96fce670e5 to your computer and use it in GitHub Desktop.
# .circleci/.configure_aws_template.sh
payment_processing_server_ip=$([ $1 = "prod" ] && echo "54.90.113.155" || echo "18.170.1.160");
sed -i 's/CARBN_PAYMENT_PROCESSING_SERVER_IP_ADDRESS/'${payment_processing_server_ip}'/g' template.yaml;
# ----------------------------------------------------- #
# template.yaml
CARBN_ENV_PaymentProcessingAPI:
Type: AWS::Serverless::Api
Properties:
OpenApiVersion: '3.0.1'
Name: CARBN_API_STACK-payments
StageName: CARBN_API_STAGE_NAME
Auth:
ResourcePolicy:
IpRangeWhitelist:
- !Ref PaymentProcessingServerIPAddress
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment