Category : kubectl

Kubernetes refuses my yaml file even though it looks fine to me. Do you have any suggestions? Thank you very much in advance. apiVersion: apps/v1 kind: Deployment metadata: name: mongodb-deployment labels: app: mongodb spec: replicas: 1 selector: matchLabels: app: mongodb template: metadata: labels: app: mongodb spec: containers: – name: mongodb image: mongo ports: – containerPort: ..

Read more

I am deploying new deployment after changes in kubernetes service. But I am facing strange issue. When I delete deployment, it deleted fine but its replica sets and pods not deleted. Therefor after apply that deployment again, new replica sets and pods created. But that newly created pods throws "FailedScheduling" error with message "0/1 nodes ..

Read more

I am using ruby kubeclient library and Kubernetes APIs to read file contents from different pod from the current pod. I have set up RBAC and am able to authenticate my Kubernetes API. Followed: https://kubernetes.io/docs/tasks/run-application/access-api-from-pod/ To read the file from the pod from the host I was able to try the below options: using kubectl ..

Read more

I’m kubernetes running on windows using docker desktop Cluster info Kubernetes control plane is running at https://kubernetes.docker.internal:6443 CoreDNS is running at https://kubernetes.docker.internal:6443/api/v1/namespaces/kube-system/services/kube-dns:dns/proxy To further debug and diagnose cluster problems, use ‘kubectl cluster-info dump’. The angular deployment file used apiVersion: apps/v1 kind: Deployment metadata: name: frontend labels: app: angular tier: frontend spec: replicas: 1 selector: matchLabels: ..

Read more

Here’s a scenario: Host (local computer running macOS) has access to the number of services running on various IPs within the 127.1.1.0/24 network range. That network is not a real local network, but instead done through kubectl port-forward (and maybe some other magic xD). That basically gives host access to the services running in the ..

Read more

I need to fill the my document root /nfsshare shared via nfs but after the volume pvc is mounted, how to delay the execution of the script ? apiVersion: apps/v1 kind: Deployment metadata: name: nfs-server spec: replicas: 1 selector: matchLabels: role: nfs-server template: metadata: labels: role: nfs-server spec: volumes: – name: nfs-vol persistentVolumeClaim: claimName: nfs-vol-pvc ..

Read more

I need to fill the my document root /nfsshare shared via nfs but after the volume pvc is mounted, how to delay the execution of the script ? apiVersion: apps/v1 kind: Deployment metadata: name: nfs-server spec: replicas: 1 selector: matchLabels: role: nfs-server template: metadata: labels: role: nfs-server spec: volumes: – name: nfs-vol persistentVolumeClaim: claimName: nfs-vol-pvc ..

Read more

When i ran kubectl exec -it /bin/bash, i got error like this OCI runtime exec failed: exec failed: container_linux.go:349: starting container process caused "exec: "env": executable file not found in $PATH": unknown command terminated with exit code 126 i made several retries using kubectl and docker exec as but nothing works on google container optimized ..

Read more