EKS Task
NextCloud Running On Amazon EKS Using EFS Storage
About EKS
Amazon Elastic Kubernetes Service (Amazon EKS) is a fully managed Kubernetes service. Customers such as Intel, Snap, Intuit, GoDaddy, and Autodesk trust EKS to run their most sensitive and mission-critical applications because of its security, reliability, and scalability.
EKS is the best place to run Kubernetes for several reasons. First, you can choose to run your EKS clusters using AWS Fargate, which is a serverless compute for containers. Fargate removes the need to provision and manage servers, lets you specify and pay for resources per application, and improves security through application isolation by design. Second, EKS is deeply integrated with services such as Amazon CloudWatch, Auto Scaling Groups, AWS Identity and Access Management (IAM), and Amazon Virtual Private Cloud (VPC), providing you a seamless experience to monitor, scale, and load-balance your applications. Third, EKS integrates with AWS App Mesh and provides a Kubernetes native experience to consume service mesh features and bring rich observability, traffic controls and security features to applications. Additionally, EKS provides a scalable and highly-available control plane that runs across multiple availability zones to eliminate a single point of failure.
EKS runs upstream Kubernetes and is certified Kubernetes conformant so you can leverage all benefits of open source tooling from the community. You can also easily migrate any standard Kubernetes application to EKS without needing to refactor your code.
Benefits
- High Availability
- Secure
- Serverless option
- Built with the Community
How it works
Use cases
- Hybrid Deployment
- Batch Processing
- Machine Learning
- Web Applications
About Next Cloud
Nextcloud offers the industry-leading, on-premises content collaboration platform.
Our technology combines the convenience and ease of use of consumer-grade solutions like Dropbox and Google Drive with the security, privacy, and control business needs.
We help you achieve that: a safe home for all your data. Secure, under your control, and developed in an open, transparent and trustworthy way. We are Nextcloud.
Now This Is The Task which I Performed
Firstly configure aws as shown below:-
Create a cluster with cluster.yml file as shown below:-
Now Successfully created mycluster as shown below:-
Also shown in AWS web console, EKS cluster page as shown below:-
5 instance created which is shown below:-
Security Group created as shown below:-
Elastic IP created as shown below:-
Also confirmed with AWS CLI as shown below:-
Then update configure file of kubectl as shown below:-
Now Get nodes as shown below:-
Now we can also connect to the instance and go inside, Here I'm using the putty program as shown bel ow:-
Now here, I've created a new namespace as shown below:-
Now, create EFS as shown below:-
Review for EFS
Finally, EFS created successfully as shown below:-
Now, finally, we run one command to create the whole environment:-
Finally, this is NEXTCLOUD look
The image which I upload on NEXTCLOUD as shown below:
AWS FARGATE:-
AWS Fargate is a serverless compute engine for containers that work with both Amazon Elastic Container Service (ECS) and Amazon Elastic Kubernetes Service (EKS). Fargate makes it easy for you to focus on building your applications. Fargate removes the need to provision and manage servers, lets you specify and pay for resources per application, and improves security through application isolation by design.
We don't know where the Master Node is launched by EKS. But we are asked for slave node that how many PODS you need to launch. It's harder to increase RAM on the running system. It's almost impossible but storage can be increased. Worker Node is where POD and application are launched. So we want AWS to manage worker node as it is crucial too. Even PODS runs in an isolated world, still, it can be breached. So a black-box is needed and it can be given to AWS in which Kubernetes is running. So we need not worry about it. This is known as Fargate.
It provides all security and connectivity. This type of Architecture is called Server-less Architecture.
This is "fargate_cluster.yml" files for fargate cluster as shown below:-
Run this command "eksctl create cluster -f fargate_cluster.yml" as shown below:-
so, "f-mycluster" is successfully created as shown below:-
"kubectl get pods -o wide" command output shown below:-
"kubectl get all" command output shown below:-
HELM
Helm is a Kubernetes package and operations manager. A helm chart will usually contain at least a deployment and a service, but it can also contain an Ingress, Persistent Volume claim(PVC), or any other Kubernetes object.
Helm charts are used to deploy an application or one component of a larger application. Helm use tiller in the backend as a server. Helm work as a client and tiller works as a server.
Download link:- https://get.helm.sh/helm-v3.3.0-rc.1-windows-amd64.zip
Tiller
A companion server component, that runs on our Kubernetes cluster, listens for commands from the helm and handles the configuration and deployment of software releases on the cluster. Once you have the client installed, upgrade Tiller with "helm init --upgrade".
Configuring Helm
Now we will configure helm by creating an account in the helm , giving some power to the user, and then initialize it.
-> kubectl -n kube-system create serviceaccount tiller
-> kubectl create cluster rolebinding tiller --clusterrole cluster-admin
--serviceaccount=kube-system:tiller
-> helm init --service-account tiller
-> helm init --service-account tiller --upgrade
By the above commands, we configure the helm and now we can use it. After configuring Helm now we will launch Grafana using helm.
INSTALLING GRAFANA IN ITS NAMESPACE
-> helm install grafana/stable --namespace grafana --set persistence.storageClassName="gp2" --set adminPasswod=redhat --set service.type=LooadBalancer
TO USE PORT FORWARDING IN GRAFANA :
-> kubectl get svc -n grafana
-> kubectl -n grafana port-forward svc/exasperated-seal-grafana 1234:80
GreaT work !!