Skip to content

Commit

Permalink
upgrade gateway-api-controller to 0.0.16
Browse files Browse the repository at this point in the history
add required ec2 permissions for gateway-api-controller

fix: doc and missing part regarding nlb deployment
  • Loading branch information
C123R committed Oct 5, 2023
1 parent 64ef398 commit db63299
Show file tree
Hide file tree
Showing 5 changed files with 26 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module "eks_blueprints_addons" {
source = "aws-ia/eks-blueprints-addons/aws"
source = "aws-ia/eks-blueprints-addons/aws"
version = "~> 1.0"

enable_aws_load_balancer_controller = true
Expand Down Expand Up @@ -40,7 +40,8 @@ resource "aws_iam_policy" "lattice" {
"vpc-lattice:*",
"iam:CreateServiceLinkedRole",
"ec2:DescribeVpcs",
"ec2:DescribeSubnets"
"ec2:DescribeSubnets",
"ec2:DescribeTags"
],
"Resource": "*"
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,6 @@ resources:
patches:
- deploymentv2.yaml
- servicev2.yaml
- nlb.yaml
- delete-deployment-redis.yaml
- delete-service-redis.yaml
19 changes: 19 additions & 0 deletions manifests/modules/networking/vpc-lattice/abtesting/nlb.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
apiVersion: v1
kind: Service
metadata:
name: ui-nlb
annotations:
service.beta.kubernetes.io/aws-load-balancer-type: external
service.beta.kubernetes.io/aws-load-balancer-scheme: internet-facing
service.beta.kubernetes.io/aws-load-balancer-nlb-target-type: instance
namespace: ui
spec:
type: LoadBalancer
ports:
- port: 80
targetPort: 8080
name: http
selector:
app.kubernetes.io/name: ui
app.kubernetes.io/instance: ui
app.kubernetes.io/component: service
3 changes: 2 additions & 1 deletion website/docs/networking/vpc-lattice/lattice-ab-testing.md
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,7 @@ Let's ensure that the UI pods are restarted and then port-forward to the preview
```bash
$ kubectl rollout restart deployment/ui -n ui
$ kubectl rollout status deployment/ui -n ui
$ kubectl port-forward svc/ui 8080:80 -n ui
```

Let us try to access our application using the browser. A `LoadBalancer` type service named `ui-nlb` is provisioned in the `ui` namespace from which the application's UI can be accessed.
Expand All @@ -154,4 +155,4 @@ Access this in your browser and try to checkout multiple times (with different i

You'll notice that the checkout now uses the "Lattice checkout" pods about 75% of the time:

![Lattice Checkout](assets/latticecheckout.png)
![Lattice Checkout](assets/latticecheckout.png)
2 changes: 1 addition & 1 deletion website/docs/networking/vpc-lattice/setup.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ This step will install the controller and the CRDs (Custom Resource Definitions)
$ aws ecr-public get-login-password --region us-east-1 | helm registry login --username AWS --password-stdin public.ecr.aws
$ helm install gateway-api-controller \
oci://public.ecr.aws/aws-application-networking-k8s/aws-gateway-controller-chart \
--version=v0.0.15 \
--version=v0.0.16 \
--create-namespace \
--set=aws.region=${AWS_REGION} \
--set serviceAccount.annotations."eks\.amazonaws\.com/role-arn"="$LATTICE_IAM_ROLE" \
Expand Down

0 comments on commit db63299

Please sign in to comment.