Skip to content

Commit

Permalink
review feedback
Browse files Browse the repository at this point in the history
Signed-off-by: Jack Francis <[email protected]>
  • Loading branch information
jackfrancis committed Jun 6, 2024
1 parent 99beb08 commit de9c64b
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 5 deletions.
1 change: 0 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,6 @@ export RANDOM_SUFFIX := $(shell /bin/bash -c "echo $$RANDOM")
export AZWI_RESOURCE_GROUP ?= capz-wi-$(RANDOM_SUFFIX)
export CI_RG ?= $(AZWI_RESOURCE_GROUP)
export USER_IDENTITY ?= $(addsuffix $(RANDOM_SUFFIX),$(CI_RG))
export AZWI_LOCATION ?= eastus
export AZURE_IDENTITY_ID_FILEPATH ?= $(ROOT_DIR)/azure_identity_id

## --------------------------------------
Expand Down
2 changes: 2 additions & 0 deletions hack/log/redact.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,12 @@ redact_vars=(
"${AZURE_SUBSCRIPTION_ID:-}"
"${AZURE_TENANT_ID:-}"
"${AZURE_JSON_B64:-}"
"${AZURE_CLIENT_ID_USER_ASSIGNED_IDENTITY:-}"
"$(echo -n "${AZURE_SUBSCRIPTION_ID:-}" | base64 | tr -d '\n')"
"$(echo -n "${AZURE_TENANT_ID:-}" | base64 | tr -d '\n')"
"$(echo -n "${AZURE_CLIENT_ID:-}" | base64 | tr -d '\n')"
"$(echo -n "${AZURE_CLIENT_SECRET:-}" | base64 | tr -d '\n')"
"$(echo -n "${AZURE_CLIENT_ID_USER_ASSIGNED_IDENTITY:-}" | base64 | tr -d '\n')"
)

for log_file in "${log_files[@]}"; do
Expand Down
5 changes: 1 addition & 4 deletions scripts/kind-with-registry.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ AZWI_ENABLED="${AZWI_ENABLED:-true}"
RANDOM_SUFFIX="${RANDOM_SUFFIX:-$RANDOM}"
export AZWI_STORAGE_ACCOUNT="oidcissuer${RANDOM_SUFFIX}"
export AZWI_STORAGE_CONTAINER="\$web"
export AZWI_LOCATION="${AZURE_LOCATION:-southcentralus}"
export SERVICE_ACCOUNT_ISSUER="${SERVICE_ACCOUNT_ISSUER:-}"
export SERVICE_ACCOUNT_SIGNING_PUB_FILEPATH="${SERVICE_ACCOUNT_SIGNING_PUB_FILEPATH:-}"
export SERVICE_ACCOUNT_SIGNING_KEY_FILEPATH="${SERVICE_ACCOUNT_SIGNING_KEY_FILEPATH:-}"
Expand Down Expand Up @@ -92,10 +93,6 @@ function checkAZWIENVPreReqsAndCreateFiles() {
echo "AZWI_RESOURCE_GROUP environment variable required - Azure resource group to store required Workload Identity artifacts"
exit 1
fi
if [ -z "${AZWI_LOCATION}" ]; then
echo "AZWI_LOCATION environment variable required - Azure location where required Workload Identity artifacts reside"
exit 1
fi
if [ "$(az group exists --name "${AZWI_RESOURCE_GROUP}" --output tsv)" == 'false' ]; then
echo "Creating resource group '${AZWI_RESOURCE_GROUP}' in '${AZWI_LOCATION}'"
az group create --name "${AZWI_RESOURCE_GROUP}" --location "${AZWI_LOCATION}" --output none --only-show-errors --tags creationTimestamp="${TIMESTAMP}" jobName="${JOB_NAME}" buildProvenance="${BUILD_PROVENANCE}"
Expand Down

0 comments on commit de9c64b

Please sign in to comment.