File tree Expand file tree Collapse file tree 2 files changed +49
-0
lines changed Expand file tree Collapse file tree 2 files changed +49
-0
lines changed Original file line number Diff line number Diff line change @@ -445,6 +445,16 @@ tasks:
445445 - func : helm_registry_login
446446 - func : publish_helm_chart
447447
448+ - name : publish_helm_chart
449+ commands :
450+ - func : clone
451+ - func : setup_kubectl
452+ - func : setup_aws
453+ - func : prepare_aws
454+ - func : helm_registry_login
455+ - func : python_venv
456+ - func : publish_helm_chart
457+
448458 - name : prepare_aws
449459 priority : 59
450460 commands :
Original file line number Diff line number Diff line change 1+ #! /usr/bin/env bash
2+
3+ ECR_REGISTRY=" 268558157000.dkr.ecr.us-east-1.amazonaws.com"
4+ AWS_REGION=" us-east-1"
5+
6+ source scripts/dev/set_env_context.sh
7+
8+ export PATH=${PROJECT_DIR} /bin:$PATH
9+
10+ echo " Checking if helm CLI is installed..."
11+ if ! command -v helm & > /dev/null
12+ then
13+ echo " Error: helm CLI could not be found."
14+ echo " Please ensure helm is installed and in your system's PATH."
15+ exit 1
16+ fi
17+
18+ echo " Checking if aws CLI is installed..."
19+ if ! command -v aws & > /dev/null
20+ then
21+ echo " Error: aws CLI could not be found."
22+ echo " Please ensure aws CLI is installed and configured."
23+ exit 1
24+ fi
25+
26+ echo " Logging into OCI Registry: ${ECR_REGISTRY} in region ${AWS_REGION} ..."
27+
28+ if aws ecr get-login-password --region " $AWS_REGION " | helm registry login \
29+ --username AWS \
30+ --password-stdin \
31+ " $ECR_REGISTRY "
32+ then
33+ echo " Helm successfully logged into the OCI registry."
34+ exit 0
35+ else
36+ echo " ERROR: Helm login to ECR registry failed."
37+ echo " Please ensure your AWS credentials have permission to access ECR in the specified region."
38+ exit 1
39+ fi
You can’t perform that action at this time.
0 commit comments