|
| 1 | +# Single New EKS Cluster Observability Accelerator |
| 2 | + |
| 3 | +## Objective |
| 4 | + |
| 5 | +This pattern deploys one production grade Amazon EKS cluster, without any Observability add-on. |
| 6 | + |
| 7 | +## Prerequisites: |
| 8 | + |
| 9 | +Ensure that you have installed the following tools on your machine. |
| 10 | + |
| 11 | +1. [aws cli](https://docs.aws.amazon.com/cli/latest/userguide/install-cliv2.html) |
| 12 | +2. [kubectl](https://Kubernetes.io/docs/tasks/tools/) |
| 13 | +3. [cdk](https://docs.aws.amazon.com/cdk/v2/guide/getting_started.html#getting_started_install) |
| 14 | +4. [npm](https://docs.npmjs.com/cli/v8/commands/npm-install) |
| 15 | + |
| 16 | +## Deploying |
| 17 | + |
| 18 | +1. Clone your forked repository |
| 19 | + |
| 20 | +```sh |
| 21 | +git clone https://github.com/aws-observability/cdk-aws-observability-accelerator.git |
| 22 | +``` |
| 23 | + |
| 24 | +2. Install the AWS CDK Toolkit globally on your machine using |
| 25 | + |
| 26 | +```bash |
| 27 | +npm install -g aws-cdk |
| 28 | +``` |
| 29 | + |
| 30 | +3. Install project dependencies by running `npm install` in the main folder of this cloned repository |
| 31 | + |
| 32 | +4. Once all pre-requisites are set you are ready to deploy the pipeline. Run the following command from the root of this repository to deploy the pipeline stack: |
| 33 | + |
| 34 | +```bash |
| 35 | +make build |
| 36 | +make pattern single-new-eks-cluster deploy |
| 37 | +``` |
| 38 | + |
| 39 | +## Verify the resources |
| 40 | + |
| 41 | +Run update-kubeconfig command. You should be able to get the command from CDK output message. |
| 42 | + |
| 43 | +```bash |
| 44 | +aws eks update-kubeconfig --name single-new-eks-observability-accelerator --region <your region> --role-arn arn:aws:iam::xxxxxxxxx:role/single-new-eks-observabil-singleneweksobservabilit-5NW0A5AUXVS9 |
| 45 | +``` |
| 46 | + |
| 47 | +Let’s verify the resources created by steps above. |
| 48 | + |
| 49 | +```bash |
| 50 | +kubectl get nodes -o wide |
| 51 | +``` |
| 52 | +Output: |
| 53 | + |
| 54 | +```console |
| 55 | +NAME STATUS ROLES AGE VERSION INTERNAL-IP EXTERNAL-IP OS-IMAGE KERNEL-VERSION CONTAINER-RUNTIME |
| 56 | +ip-10-0-157-151.eu-central-1.compute.internal Ready <none> 9m19s v1.25.9-eks-0a21954 10.0.157.151 <none> Amazon Linux 2 5.10.179-168.710.amzn2.x86_64 containerd://1.6.19 |
| 57 | +``` |
| 58 | + |
| 59 | +Next, lets verify the namespaces in the cluster: |
| 60 | + |
| 61 | +```bash |
| 62 | +kubectl get ns # Output shows all namespace |
| 63 | +``` |
| 64 | + |
| 65 | +Output: |
| 66 | + |
| 67 | +```console |
| 68 | +NAME STATUS AGE |
| 69 | +cert-manager Active 7m8s |
| 70 | +default Active 13m |
| 71 | +external-secrets Active 7m9s |
| 72 | +kube-node-lease Active 13m |
| 73 | +kube-public Active 13m |
| 74 | +kube-system Active 13m |
| 75 | +prometheus-node-exporter Active 7m9s |
| 76 | +``` |
| 77 | + |
| 78 | +## Teardown |
| 79 | + |
| 80 | +You can teardown the whole CDK stack with the following command: |
| 81 | + |
| 82 | +```bash |
| 83 | +make pattern single-new-eks-cluster destroy |
| 84 | +``` |
| 85 | + |
| 86 | +aws |
0 commit comments