| 1 | import type * as eks from "@distilled.cloud/aws/eks"; |
| 2 | import type * as Effect from "effect/Effect"; |
| 3 | import * as Binding from "../../Binding.ts"; |
| 4 | import type { Cluster } from "./Cluster.ts"; |
| 5 | |
| 6 | /** |
| 7 | * Runtime binding for `eks:DescribePodIdentityAssociation`. |
| 8 | * |
| 9 | * Reads one EKS Pod Identity association — the IAM role wired to a Kubernetes service account. |
| 10 | * The cluster `clusterName` is injected from the bound {@link Cluster} and `eks:DescribePodIdentityAssociation` is granted on the cluster's sub-resource ARNs. |
| 11 | * Provide the implementation with |
| 12 | * `Effect.provide(AWS.EKS.DescribePodIdentityAssociationHttp)`. |
| 13 | * ### Inspecting Identity and Access |
| 14 | * **Example:** Read a Pod Identity Association |
| 15 | * ```typescript |
| 16 | * // init |
| 17 | * const describePodIdentityAssociation = |
| 18 | * yield* AWS.EKS.DescribePodIdentityAssociation(cluster); |
| 19 | * |
| 20 | * // runtime |
| 21 | * const { association } = yield* describePodIdentityAssociation({ |
| 22 | * associationId, |
| 23 | * }); |
| 24 | * ``` |
| 25 | * |
| 26 | * @binding |
| 27 | */ |
| 28 | export interface DescribePodIdentityAssociation extends Binding.Service< |
| 29 | DescribePodIdentityAssociation, |
| 30 | "AWS.EKS.DescribePodIdentityAssociation", |
| 31 | ( |
| 32 | cluster: Cluster, |
| 33 | ) => Effect.Effect< |
| 34 | ( |
| 35 | request: Omit<eks.DescribePodIdentityAssociationRequest, "clusterName">, |
| 36 | ) => Effect.Effect< |
| 37 | eks.DescribePodIdentityAssociationResponse, |
| 38 | eks.DescribePodIdentityAssociationError |
| 39 | > |
| 40 | > |
| 41 | > {} |
| 42 | export const DescribePodIdentityAssociation = |
| 43 | Binding.Service<DescribePodIdentityAssociation>( |
| 44 | "AWS.EKS.DescribePodIdentityAssociation", |
| 45 | ); |