sts-cmd¶
get session token¶
export CRED=$(aws sts get-session-token --duration-seconds 86400)
export AWS_ACCESS_KEY_ID=$(echo "${CRED}" | jq -r '.Credentials.AccessKeyId')
export AWS_SECRET_ACCESS_KEY=$(echo "${CRED}" | jq -r '.Credentials.SecretAccessKey')
export AWS_SESSION_TOKEN=$(echo "${CRED}" | jq -r '.Credentials.SessionToken')