Skip to content

utrains/geoMVPX0

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Geolocation Project : Create cluster and install Argo-CD in thios Cluster

Prerequisites:

  • Have AWS CLI and eksctl installed
  • Have an AWS account with sufficient IAM permissions to create clusters, IAM roles, and EBS volumes
  • Have kubectl installed and configured for Kubernetes operations

Create your EKS cluster in AWS

To create the EKS cluster for this lab, use the following commands:

1. Set up a directory for cluster configuration:
mkdir eks-argo-geolocation
cd eks-argo-geolocation

2. Verify your AWS identity:
aws sts get-caller-identity

3. Create an EKS cluster:
eksctl create cluster --name geolocation-cluster --region us-east-1 --nodegroup-name my-nodes --node-type t3.medium --nodes 2 --nodes-min 1 --nodes-max 2

4- Update the kubeconfig for the new cluster:
aws eks --region us-east-1 update-kubeconfig --name geolocation-cluster

5- Verify Cluster Nodes:
kubectl get nodes

Install and start Argo CD in a Kubernetes cluster

# install ArgoCD in k8s cluster

# create a namespace for argo CD
kubectl create namespace argocd

# install argo CD on the created namespace
kubectl apply -n argocd -f https://raw.githubusercontent.com/argoproj/argo-cd/stable/manifests/install.yaml

# check the pods created
kubectl get pods -n argocd

# check the services
kubectl get svc -n argocd

# Change the argocd-server service type to LoadBalancer
kubectl patch svc argocd-server -n argocd -p '{"spec": {"type": "LoadBalancer"}}'

# Show services and Copy the dns name of Loadbalancer from argocd-server service
kubectl get svc -n argocd

# get the password to connect to the admin account
kubectl -n argocd get secret argocd-initial-admin-secret -o jsonpath="{.data.password}" | base64 -d; echo

# Connect on the Argo UI with username: admin and the password generated by the below command

# you can change and delete init password

Delete resources : After the Lab, you can use thios to delete the Infra cluster

After successfully done this lab, you must delete all the resources created to avoid charges:

1. Delete the Argo CD application:
kubectl delete -f application.yaml -n argocd

2. Delete all resources inside argocd namespace:
kubectl delete all --all -n argocd

3. Delete argocd and myapp namespaces:
kubectl delete namespace argocd
kubectl delete namespace myapp

4. Delete the EKS cluster:
eksctl delete cluster --name geolocation-cluster --region us-east-1


About

Geolocation Minimum Value Project X0

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors