Questions tagged [kubernetes-deployment]

260 questions
91
votes
6 answers

Helm V3 - Cannot find the official repo

I have been trying to install nginx ingress using helm version 3 helm install my-ingress stable/nginx-ingress But Helm doesn't seem to be able to find it's official stable repo. It gives the message: Error: failed to download…
Charlie
  • 22,886
  • 11
  • 59
  • 90
73
votes
18 answers

Kubernetes create deployment unexpected SchemaError

I'm following that tutorial (https://www.baeldung.com/spring-boot-minikube) I want to create Kubernetes deployment in yaml file (simple-crud-dpl.yaml): apiVersion: apps/v1 kind: Deployment metadata: name: simple-crud spec: selector: …
Arkadiusz Migała
  • 927
  • 1
  • 8
  • 14
29
votes
6 answers

Can not delete pods in Kubernetes

I tried installing dgraph (single server) using Kubernetes. I created pod using: kubectl create -f https://raw.githubusercontent.com/dgraph-io/dgraph/master/contrib/config/kubernetes/dgraph-single.yaml Now all I need to do is to delete the created…
28
votes
3 answers

Why do we need a port/containerPort in a Kuberntes deployment/container definition?

When I define e.g. a deployment in Kubernetes there is a section with a list of containers and each of them contains an array of ports, e.g.: apiVersion: apps/v1 kind: Deployment spec: template: spec: containers: - name: my-nginx …
20
votes
5 answers

Why labels are mentioned three times in a single deployment

I've gone over the following docomentation page: https://kubernetes.io/docs/concepts/workloads/controllers/deployment/ The example deployment yaml is as follows: apiVersion: apps/v1 kind: Deployment metadata: name: nginx-deployment labels: …
Mugen
  • 8,301
  • 10
  • 62
  • 140
16
votes
2 answers

Kubernetes: How to set boolean type variable in configMap

I want to set a boolean variable in configMap (or secret): apiVersion: v1 kind: ConfigMap metadata: name: env-config namespace: mlo-stage data: webpack_dev_server: false But when I apply it, I get the following error: The request is invalid:…
Ken Tsoi
  • 1,195
  • 1
  • 17
  • 37
15
votes
2 answers

Is there a concept of inheritance for Kubernetes deployments?

Is there a way to create a tree of inheritance for Kubernetes deployments? I have a number of deployments which are similar but not identical. They share many ENV vars but not all. They all use the same image. For example, I have a dev deployment…
timthelion
  • 2,636
  • 2
  • 21
  • 30
14
votes
1 answer

K8S Pod with startupProbe and initialDelaySeconds specified waits too long to become Ready

I have been trying to debug a very odd delay in my K8S deployments. I have tracked it down to the simple reproduction below. What it appears is that if I set an initialDelaySeconds on a startup probe or leave it 0 and have a single failure, then…
Allen
  • 3,134
  • 5
  • 29
  • 49
14
votes
2 answers

defining 2 ports in deployment.yaml in Kubernetes

I have a docker image from I am doing docker run --name test -h test -p 9043:9043 -p 9443:9443 -d ibmcom/websphere-traditional:install I am trying to put into a kubernetes deploy file and I have this: apiVersion: extensions/v1beta1 kind:…
Adam
  • 1,157
  • 6
  • 19
  • 40
13
votes
3 answers

scale down kubernetes deployments to 0 and scale back to original number of replica sets

I have written a bash script to get all deployments on a kubernetes cluster. I have a command to scale all the deployments to zero. The challenge I am having is that, I want to be able to loop through all the deployments and save their name and…
13
votes
5 answers

Kubernetes "the server doesn't have a resource type deployments"

I'm new on kubernetes. I couldn't get deployments using kubectl but I can see all deployments on kubernetes dashboard. How can i fix this problem? user@master:~$ kubectl get deployments error: the server doesn't have a resource type…
AliCan Sahin
  • 190
  • 1
  • 1
  • 6
13
votes
2 answers

How to select a specific pod for a service in Kubernetes

I have a kubernetes cluster of 3 hosts where each Host has a unique id label. On this cluster, there is a software that has 3 instances (replicas). Each replica requires to talk to all other replicas. In addition, there is a service that contains…
Hotstepper13
  • 173
  • 1
  • 1
  • 8
12
votes
1 answer

RBAC role to manage single pod with dynamic name

I need to grant access to one deployment and all pods of this deployment using RBAC. I've managed to configure Role and RoleBinding for the deploymet, and it's working fine: --- kind: Role apiVersion: rbac.authorization.k8s.io/v1beta1 metadata: …
Kirill
  • 7,580
  • 6
  • 44
  • 95
11
votes
1 answer

Setup securityContext inside kubernetes deployment

I'm using a nfs mounted volume in my deployments. I need to give it the fsGroup like below: securityContext: runAsUser: 1000 runAsGroup: 3000 fsGroup: 2000 Is there a way to make this on the deployment manifest? As I can see on the…
10
votes
2 answers

What is difference between Kubernetes Jobs & Deployments

I see that Kubernetes Job & Deployment provide very similar configuration. Both can deploy one or more pods with certain configuration. So I have few queries around these: Is the pod specification .spec.template different in Job & Deployment? What…
Mukund Jalan
  • 1,145
  • 20
  • 39
1
2 3
17 18