CLI로 DescribeFargateProfile 사용 - AWS SDK 코드 예제

AWS SDK 예제 GitHub 리포지토리에 더 많은 AWS문서 SDK 예제가 있습니다.

CLI로 DescribeFargateProfile 사용

다음 코드 예시는 DescribeFargateProfile의 사용 방법을 보여 줍니다.

CLI
AWS CLI

Fargate 프로파일 설명

다음 describe-fargate-profile 예시에서는 Fargate 프로파일을 설명합니다.

aws eks describe-fargate-profile \ --cluster-name my-eks-cluster \ --fargate-profile-name my-fargate-profile

출력:

{ "fargateProfile": { "fargateProfileName": "my-fargate-profile", "fargateProfileArn": "arn:aws:eks:us-east-2:111122223333:fargateprofile/my-eks-cluster/my-fargate-profile/96c766ce-43d2-f9c9-954c-647334391198", "clusterName": "my-eks-cluster", "createdAt": "2024-04-11T10:42:52.486000-04:00", "podExecutionRoleArn": "arn:aws:iam::111122223333:role/eksctl-my-eks-cluster-farga-FargatePodExecutionRole-1htfAaJdJUEO", "subnets": [ "subnet-09d912bb63ef21b9a", "subnet-04ad87f71c6e5ab4d", "subnet-0e2907431c9988b72" ], "selectors": [ { "namespace": "prod*", "labels": { "labelname*?": "*value1" } }, { "namespace": "*dev*", "labels": { "labelname*?": "*value*" } } ], "status": "ACTIVE", "tags": { "eks-fargate-profile-key-2": "value-2", "eks-fargate-profile-key-1": "value-1" } } }
PowerShell
Tools for PowerShell V4

예제 1: 이 cmdlet은 AWS Fargate 프로파일에 대한 설명 정보를 반환합니다.

Get-EKSFargateProfile -FargateProfileName "EKSFargate" -ClusterName "TEST"

출력:

ClusterName : TEST CreatedAt : 12/26/2019 12:34:47 PM FargateProfileArn : arn:aws:eks:us-east-2:012345678912:fargateprofile/TEST/EKSFargate/42b7a119-e16b-a279-ce97-bdf303adec92 FargateProfileName : EKSFargate PodExecutionRoleArn : arn:aws:iam::012345678912:role/AmazonEKSFargatePodExecutionRole Selectors : {Amazon.EKS.Model.FargateProfileSelector} Status : ACTIVE Subnets : {subnet-0cd976f08d5fbfaae, subnet-02f6ff500ff2067a0} Tags : {}
  • API 세부 정보는 AWS Tools for PowerShell Cmdlet 참조(V4)DescribeFargateProfile을 참조하세요.

Tools for PowerShell V5

예제 1: 이 cmdlet은 AWS Fargate 프로파일에 대한 설명 정보를 반환합니다.

Get-EKSFargateProfile -FargateProfileName "EKSFargate" -ClusterName "TEST"

출력:

ClusterName : TEST CreatedAt : 12/26/2019 12:34:47 PM FargateProfileArn : arn:aws:eks:us-east-2:012345678912:fargateprofile/TEST/EKSFargate/42b7a119-e16b-a279-ce97-bdf303adec92 FargateProfileName : EKSFargate PodExecutionRoleArn : arn:aws:iam::012345678912:role/AmazonEKSFargatePodExecutionRole Selectors : {Amazon.EKS.Model.FargateProfileSelector} Status : ACTIVE Subnets : {subnet-0cd976f08d5fbfaae, subnet-02f6ff500ff2067a0} Tags : {}
  • API 세부 정보는 AWS Tools for PowerShell Cmdlet 참조(V5)DescribeFargateProfile을 참조하세요.