Kubernetes Interview Questions:
==============================
1).What is Deamonset into the kubernetes?
Deamonset:
2).what is the deployment into kubernestes?
=================
apiVersion: apps/v1
kind: Deployment
metadata:
name: nginx-deployment
labels:
app: nginx
spec:
replicas: 2
selector:
matchLabels:
app: nginx
template:
metadata:
labels:
app: nginx
spec:
containers:
- name: nginx
image: nginx:latest
ports:
- containerPort: 80
===============================
3).what is the statefulset into kubernetes?
apiVersion: apps/v1
kind: StatefulSet
metadata:
name: mysql
spec:
serviceName: mysql
replicas: 3
selector:
matchLabels:
app: mysql
template:
metadata:
labels:
app: mysql
spec:
containers:
- name: mysql
image: mysql:8
volumeMounts:
- name: data
mountPath: /var/lib/mysql
volumeClaimTemplates:
- metadata:
name: data
spec:
accessModes: ["ReadWriteOnce"]
resources:
requests:
storage: 10Gi
4).what is the sue of service account into kubernestes into it ?
=========================================================
A ServiceAccount provides an identity to pods so that Kubernetes can authenticate and authorize their access to cluster resources using RBAC.”
=========================================================
apiVersion: v1
kind: ServiceAccount
metadata:
name: app-sa
===========================
apiVersion: v1
kind: Pod
metadata:
name: my-pod
spec:
serviceAccountName: app-sa
containers:
- name: app
image: nginx
=============================
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
name: pod-reader
rules:
- apiGroups: [""]
resources: ["pods"]
verbs: ["get", "list"]
==============================''
apiVersion: rbac.authorization.k8s.io/v1
kind: RoleBinding
metadata:
name: read-pods
subjects:
- kind: ServiceAccount
name: app-sa
roleRef:
kind: Role
name: pod-reader
apiGroup: rbac.authorization.k8s.io
=======================
5).what is the pod into the kubernestes into it ?
apiVersion: v1
kind: Pod
metadata:
name: my-pod
labels:
app: demo
spec:
containers:
- name: nginx-container
image: nginx
ports:
- containerPort: 80
6).what is the differnt kubernestes services into it ?
nodeip
cluster port
load blnacer
external name
headless service
pods
services
cluster
rbacs
ingress controllers
master node
worker node
7).what is the side conatiner into kubernetes?
8).what is crashloop error ?
9).what is configmap into kubenrrstes ?
capiVersion: v1
kind: ConfigMap
metadata:
name: simple-config
data:
APP_NAME: myapp
APP_ENV: dev
=================
kubectl apply -f configmap.yaml
==================
kubectl get configmap
kubectl describe configmap simple-config
10).what is secretes into kubernestes into it ?
====================================================================
AWS Interview Questions:
1).could you please explain the spot instances and configuring about the spot ec2 instances into aws environment ? 2).what is the mfa and how to configure the mfa into iam ? 3).security groups and tell about it the concepts 4).vpc endpoints and how to configure the those things ? 5).vpc flow logs 6).AWS CLI into aws environment? ------------------------------------------------ AWS Interview Questions: 1).IAM roles into aws environment: 2).Custom IAM role and policy into aws environment? IAM Role : which is used to establish the communication between the different iam services into aws environment IAM policy into aws environment: which is use to tell us what kind of activity you can perform on each services into aws environments: maybe it would be like as the, read ,write and execute How to create IAM role and policy into aws environment? first create the iam role without allocated the policy: give the aws services choose use case or aws services then don't choose any policy ...
Comments
Post a Comment