general:domain:"REPLACEME.com"ingress:enabled:trueclassName:"nginx"## - Annotations to add to the Ingress resourceannotations:nginx.ingress.kubernetes.io/ssl-redirect:"true"nginx.ingress.kubernetes.io/use-regex:"true"nginx.ingress.kubernetes.io/rewrite-target:/$1## - Labels to add to the Ingress resourcelabels:{}# Certificate optionstls:# TLS certificate secret namename:# Handled via the NLB defined in the ingress controller# Cluster cert issuer (ex. Let's Encrypt) name if one existsclusterIssuer:paths:web:path:/(.*)pathType:ImplementationSpecificattachments:path:/attachments/(.*)pathType:ImplementationSpecificapi:path:/api/(.*)pathType:ImplementationSpecificicons:path:/icons/(.*)pathType:ImplementationSpecificnotifications:path:/notifications/(.*)pathType:ImplementationSpecificevents:path:/events/(.*)pathType:ImplementationSpecificscim:path:/scim/(.*)pathType:ImplementationSpecificsso:path:/(sso/.*)pathType:ImplementationSpecificidentity:path:/(identity/.*)pathType:ImplementationSpecificadmin:path:/(admin/?.*)pathType:ImplementationSpecific
file_system_id="REPLACE"cat<<EOF|kubectlapply-nbitwarden-f-kind: StorageClassapiVersion: storage.k8s.io/v1metadata: name: shared-storageprovisioner: efs.csi.aws.comparameters: provisioningMode: efs-ap fileSystemId: $file_system_id directoryPerms: "777" # Change for your use case uid: "2000" # Change for your use case gid: "2000" # Change for your use case basePath: "/dyn1" subPathPattern: "\${.PVC.name}" ensureUniqueDirectory: "false" reuseAccessPoint: "false"mountOptions: - iam - tlsEOF
CLUSTER_NAME="REPLACE"ACCOUNT_ID="REPLACE"# replace with your AWS account IDROLE_NAME="REPLACE"# name of a role that will be created in IAMPOLICY_NAME="REPLACE"# the name of the policy you created earliereksctlcreateiamserviceaccount \--cluster=$CLUSTER_NAME \--namespace=bitwarden \--name=bitwarden-sa \--role-name $ROLE_NAME \--attach-policy-arn=arn:aws:iam::$ACCOUNT_ID:policy/$POLICY_NAME \--approve
4、接下来,创建 SecretProviderClass,如以下示例所示。请务必将 region 替换为您所在的区域,并将objectName 替换为您创建的 Secrets Manager 机密的名称(步骤 1):