Skip to content

Commit

Permalink
Update aws-vault roles
Browse files Browse the repository at this point in the history
  • Loading branch information
sabiurr committed Sep 12, 2023
1 parent 41a2694 commit 5566882
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 11 deletions.
6 changes: 3 additions & 3 deletions aws/logs_monitoring/release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -49,12 +49,12 @@ function aws-login() {
cfg=( "$@" )
shift
if [ "$ACCOUNT" = "prod" ] ; then
aws-vault exec prod-engineering -- ${cfg[@]}
aws-vault exec sso-prod-engineering -- ${cfg[@]}
else
if [ "$DEPLOY_TO_SERVERLESS_SANDBOX" = "true" ] ; then
aws-vault exec serverless-sandbox-account-admin -- ${cfg[@]}
aws-vault exec sso-serverless-sandbox-account-admin -- ${cfg[@]}
else
aws-vault exec sandbox-account-admin -- ${cfg[@]}
aws-vault exec sso-sandbox-account-admin -- ${cfg[@]}
fi
fi
}
Expand Down
6 changes: 3 additions & 3 deletions aws/logs_monitoring/tools/installation_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -37,12 +37,12 @@ function aws-login() {
cfg=( "$@" )
shift
if [ "$ACCOUNT" = "prod" ] ; then
aws-vault exec prod-engineering -- ${cfg[@]}
aws-vault exec sso-prod-engineering -- ${cfg[@]}
else
if [ "$DEPLOY_TO_SERVERLESS_SANDBOX" = "true" ] ; then
aws-vault exec serverless-sandbox-account-admin -- ${cfg[@]}
aws-vault exec sso-serverless-sandbox-account-admin -- ${cfg[@]}
else
aws-vault exec sandbox-account-admin -- ${cfg[@]}
aws-vault exec sso-sandbox-account-admin -- ${cfg[@]}
fi
fi
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ do
# Run additionalLambda tests

# Requires AWS credentials
# Use aws-vault exec sandbox-account-admin -- ./integration_tests.sh
# Use aws-vault exec sso-sandbox-account-admin -- ./integration_tests.sh
-a|--additional-lambda)
ADDITIONAL_LAMBDA=true
shift
Expand Down Expand Up @@ -249,4 +249,4 @@ if [ $CACHE_TEST == true ]; then
aws s3api delete-bucket --bucket $DD_S3_BUCKET_NAME

rm policy.json
fi
fi
4 changes: 2 additions & 2 deletions aws/logs_monitoring/tools/publish_prod.sh
Original file line number Diff line number Diff line change
Expand Up @@ -39,12 +39,12 @@ fi
# Ensure AWS access before proceeding
SAML2AWS_IDP_PROVIDER=Browser ddsaml2aws login -a govcloud-us1-fed-human-engineering
AWS_PROFILE=govcloud-us1-fed-human-engineering aws sts get-caller-identity
aws-vault exec prod-engineering -- aws sts get-caller-identity
aws-vault exec sso-prod-engineering -- aws sts get-caller-identity

echo "Publishing layers to GovCloud AWS regions"
SAML2AWS_IDP_PROVIDER=Browser ddsaml2aws login -a govcloud-us1-fed-human-engineering
LAYER_VERSION=$LAYER_VERSION FORWARDER_VERSION=$FORWARDER_VERSION AWS_PROFILE=govcloud-us1-fed-human-engineering ./tools/publish_layers.sh

echo
echo "Publishing layers to commercial AWS regions"
LAYER_VERSION=$LAYER_VERSION FORWARDER_VERSION=$FORWARDER_VERSION aws-vault exec prod-engineering -- ./tools/publish_layers.sh
LAYER_VERSION=$LAYER_VERSION FORWARDER_VERSION=$FORWARDER_VERSION aws-vault exec sso-prod-engineering -- ./tools/publish_layers.sh
2 changes: 1 addition & 1 deletion aws/logs_monitoring/tools/publish_sandbox.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@ fi

echo "FORWARDER_VERSION=$FORWARDER_VERSION"

LAYER_VERSION=$LAYER_VERSION FORWARDER_VERSION=$FORWARDER_VERSION aws-vault exec sandbox-account-admin -- ./tools/publish_layers.sh
LAYER_VERSION=$LAYER_VERSION FORWARDER_VERSION=$FORWARDER_VERSION aws-vault exec sso-sandbox-account-admin -- ./tools/publish_layers.sh

0 comments on commit 5566882

Please sign in to comment.