Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,17 @@ if [ -z "${REGION:-}" ]; then
exit 1
fi

TFSTATE_BUCKET=$(yaml_value "tfstate_bucket" "" "$VALUES")
AWS_PROFILE_VAL=$(yaml_value "aws_profile" "" "$VALUES")

if [ -n "${AWS_PROFILE_VAL}" ] && [ -z "${AWS_PROFILE:-}" ]; then
export AWS_PROFILE="${AWS_PROFILE_VAL}"
fi

if [ -z "${TFSTATE_BUCKET:-}" ]; then
echo "ERROR: TFSTATE_BUCKET is not set. Expected to be exported by build_context." >&2
exit 1
fi

# --- Read service outputs (set by write_service_outputs after RDS creation) -

SERVICE_ID=$(echo "$CONTEXT" | jq -r '.service.id')
Expand Down
2 changes: 2 additions & 0 deletions databases/rds-postgres-server/workflows/aws/link.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ steps:
type: environment
- name: REGION
type: environment
- name: TFSTATE_BUCKET
type: environment
- name: LINK_ID
type: environment
- name: LINK_NAME
Expand Down
2 changes: 2 additions & 0 deletions databases/rds-postgres-server/workflows/aws/unlink.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ steps:
type: environment
- name: REGION
type: environment
- name: TFSTATE_BUCKET
type: environment
- name: LINK_ID
type: environment
- name: LINK_NAME
Expand Down
Loading