Skip to content

Commit 8f94233

Browse files
authored
doc update 0.0.4 release (#99)
Description of changes: Includes changes from #98 Testing: manually install and uninstall By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
1 parent ad50fbc commit 8f94233

File tree

1 file changed

+27
-6
lines changed

1 file changed

+27
-6
lines changed

README.md

Lines changed: 27 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -77,8 +77,8 @@ eksctl utils associate-iam-oidc-provider --cluster ${CLUSTER_NAME} \
7777

7878
Get the OIDC ID
7979
```sh
80-
AWS_ACCOUNT_ID=$(aws sts get-caller-identity --query "Account" --output text)
81-
OIDC_PROVIDER_URL=$(aws eks describe-cluster --name $CLUSTER_NAME --region $AWS_DEFAULT_REGION \
80+
export AWS_ACCOUNT_ID=$(aws sts get-caller-identity --query "Account" --output text)
81+
export OIDC_PROVIDER_URL=$(aws eks describe-cluster --name $CLUSTER_NAME --region $AWS_DEFAULT_REGION \
8282
--query "cluster.identity.oidc.issuer" --output text | cut -c9-)
8383
```
8484

@@ -110,6 +110,21 @@ printf '{
110110
' > ./trust.json
111111
```
112112

113+
Updating an ApplicationAutoscaling ScalableTarget requires the following permissions. Create a file named pass_role_policy.json to create the policy required for the IAM role.
114+
115+
```sh
116+
printf '{
117+
"Version": "2012-10-17",
118+
"Statement": [
119+
{
120+
"Effect": "Allow",
121+
"Action": "iam:PassRole",
122+
"Resource": "*"
123+
}
124+
]
125+
}
126+
' > ./pass_role_policy.json
127+
```
113128

114129
Run the following command to create a role with the trust relationship defined in `trust.json`. This role enables the Amazon EKS cluster to get and refresh credentials from IAM.
115130

@@ -118,8 +133,14 @@ OIDC_ROLE_NAME=ack-controller-role-$CLUSTER_NAME
118133

119134
aws --region $AWS_DEFAULT_REGION iam create-role --role-name $OIDC_ROLE_NAME --assume-role-policy-document file://trust.json
120135

121-
# Attach the AmazonSageMakerFullAccess Policy to the Role
136+
# Attach the AmazonSageMakerFullAccess Policy to the Role. This policy provides full access to
137+
# Amazon SageMaker. Also provides select access to related services (e.g., Application Autoscaling,
138+
# S3, ECR, CloudWatch Logs).
122139
aws --region $AWS_DEFAULT_REGION iam attach-role-policy --role-name $OIDC_ROLE_NAME --policy-arn arn:aws:iam::aws:policy/AmazonSageMakerFullAccess
140+
141+
# Attach the iam:PassRole policy required for updating ApplicationAutoscaling ScalableTarget
142+
aws iam put-role-policy --role-name $OIDC_ROLE_NAME --policy-name "iam-pass-role-policy" --policy-document file://pass_role_policy.json
143+
123144
export IAM_ROLE_ARN_FOR_IRSA=$(aws --region $AWS_DEFAULT_REGION iam get-role --role-name $OIDC_ROLE_NAME --output text --query 'Role.Arn')
124145
echo $IAM_ROLE_ARN_FOR_IRSA
125146
```
@@ -135,7 +156,7 @@ Take note of IAM_ROLE_ARN_FOR_IRSA printed in the previous step; you will pass t
135156
```sh
136157
export HELM_EXPERIMENTAL_OCI=1
137158
export SERVICE=sagemaker
138-
export RELEASE_VERSION=v0.0.3
159+
export RELEASE_VERSION=v0.0.4
139160
export CHART_EXPORT_PATH=/tmp/chart
140161
export CHART_REPO=public.ecr.aws/aws-controllers-k8s/$SERVICE-chart
141162
export CHART_REF=$CHART_REPO:$RELEASE_VERSION
@@ -184,7 +205,7 @@ helm install -n $ACK_K8S_NAMESPACE --create-namespace --skip-crds ack-$SERVICE-c
184205

185206
Verify CRDs and helm charts were deployed
186207
```sh
187-
kubectl get crds
208+
kubectl get crds | grep "k8s.aws"
188209
189210
kubectl get pods -n $ACK_K8S_NAMESPACE
190211
```
@@ -197,7 +218,7 @@ Jump to Section 4.0 if you only wish to install SageMaker controller
197218
```sh
198219
export HELM_EXPERIMENTAL_OCI=1
199220
export SERVICE=applicationautoscaling
200-
export RELEASE_VERSION=v0.0.1
221+
export RELEASE_VERSION=v0.0.2
201222
export CHART_EXPORT_PATH=/tmp/chart
202223
export CHART_REPO=public.ecr.aws/aws-controllers-k8s/$SERVICE-chart
203224
export CHART_REF=$CHART_REPO:$RELEASE_VERSION

0 commit comments

Comments
 (0)