#!/usr/bin/env bash set -euo pipefail cd "$(dirname "$0")" BASE_IMAGE="cr.yandex/crp3ccidau046kdj8g9q/terraform/terragrunt:v9.11" TARGET_IMAGE="${TARGET_IMAGE:-cr.yandex/crp3ccidau046kdj8g9q/contour/terraform-terragrunt-offline:v9.11}" rm -rf provider-mirror terraform providers mirror -platform=linux_amd64 provider-mirror docker pull --platform linux/amd64 "$BASE_IMAGE" docker build --platform linux/amd64 -t "$TARGET_IMAGE" . if [[ "${PUSH:-false}" == "true" ]]; then docker push "$TARGET_IMAGE" fi rm -rf provider-mirror