Kubernetes - can a Deployment have multiple ReplicaSets?
up vote
0
down vote
favorite
Just finished reading Nigel Poulton's The Kubernetes Book. I'm left with the question of whether or not a Deployment can specify multiple ReplicaSets.
When I think Deployment, I think of it in the traditional sense of an entire application being deployed. Or is there meant to be a Deployment for each microservice?
apiVersion: apps/v1beta2
kind: Deployment
metadata:
name: hello-deploy
spec:
replicas: 10
selector:
matchLabels:
app: hello-world
minReadySeconds: 10
strategy:
type: RollingUpdate
rollingUpdate:
maxUnavailable: 1
maxSurge: 1
template:
metadata:
labels:
app: hello-world
spec:
containers:
- name: hello-pod
image: nigelpoulton/k8sbook : latest
ports:
- containerPort: 8080
kubernetes containers microservices
add a comment |
up vote
0
down vote
favorite
Just finished reading Nigel Poulton's The Kubernetes Book. I'm left with the question of whether or not a Deployment can specify multiple ReplicaSets.
When I think Deployment, I think of it in the traditional sense of an entire application being deployed. Or is there meant to be a Deployment for each microservice?
apiVersion: apps/v1beta2
kind: Deployment
metadata:
name: hello-deploy
spec:
replicas: 10
selector:
matchLabels:
app: hello-world
minReadySeconds: 10
strategy:
type: RollingUpdate
rollingUpdate:
maxUnavailable: 1
maxSurge: 1
template:
metadata:
labels:
app: hello-world
spec:
containers:
- name: hello-pod
image: nigelpoulton/k8sbook : latest
ports:
- containerPort: 8080
kubernetes containers microservices
A deployment per microservice is common; a real application might be made of several related Deployments and Services that point at their Pods.
– David Maze
Nov 10 at 22:44
add a comment |
up vote
0
down vote
favorite
up vote
0
down vote
favorite
Just finished reading Nigel Poulton's The Kubernetes Book. I'm left with the question of whether or not a Deployment can specify multiple ReplicaSets.
When I think Deployment, I think of it in the traditional sense of an entire application being deployed. Or is there meant to be a Deployment for each microservice?
apiVersion: apps/v1beta2
kind: Deployment
metadata:
name: hello-deploy
spec:
replicas: 10
selector:
matchLabels:
app: hello-world
minReadySeconds: 10
strategy:
type: RollingUpdate
rollingUpdate:
maxUnavailable: 1
maxSurge: 1
template:
metadata:
labels:
app: hello-world
spec:
containers:
- name: hello-pod
image: nigelpoulton/k8sbook : latest
ports:
- containerPort: 8080
kubernetes containers microservices
Just finished reading Nigel Poulton's The Kubernetes Book. I'm left with the question of whether or not a Deployment can specify multiple ReplicaSets.
When I think Deployment, I think of it in the traditional sense of an entire application being deployed. Or is there meant to be a Deployment for each microservice?
apiVersion: apps/v1beta2
kind: Deployment
metadata:
name: hello-deploy
spec:
replicas: 10
selector:
matchLabels:
app: hello-world
minReadySeconds: 10
strategy:
type: RollingUpdate
rollingUpdate:
maxUnavailable: 1
maxSurge: 1
template:
metadata:
labels:
app: hello-world
spec:
containers:
- name: hello-pod
image: nigelpoulton/k8sbook : latest
ports:
- containerPort: 8080
kubernetes containers microservices
kubernetes containers microservices
asked Nov 10 at 22:26
HashRocketSyntax
473726
473726
A deployment per microservice is common; a real application might be made of several related Deployments and Services that point at their Pods.
– David Maze
Nov 10 at 22:44
add a comment |
A deployment per microservice is common; a real application might be made of several related Deployments and Services that point at their Pods.
– David Maze
Nov 10 at 22:44
A deployment per microservice is common; a real application might be made of several related Deployments and Services that point at their Pods.
– David Maze
Nov 10 at 22:44
A deployment per microservice is common; a real application might be made of several related Deployments and Services that point at their Pods.
– David Maze
Nov 10 at 22:44
add a comment |
2 Answers
2
active
oldest
votes
up vote
2
down vote
It is meant to be a deployment of each microservice.
You can also manage the quantity of "deployed services" of each microservices type.
So for instance, if you want to deploy Service A (Docker image with an Java service) 5 times, you have a deployment resulting 5 pods. Each pod contains the image of Service A.
If you deploy a new version of this Service A (Docker image with an Java service), Kubernetes is able to do a rolling update and manage the shut down of the old Java service type (the existing pods) and creates 5 new pods with the new Java Service A.2 (a new docker image).
Thus your whole microservices application/infrastructure is build upon multiple deployments. Each generating Kubernetes pods, which are published by Kubernetes services.
Well, the name Deployment is unfortunate, but at least it makes sense that you can upgrade a microservice
– HashRocketSyntax
Nov 12 at 11:22
Yup... but be warned. If you start adding Spinnaker.io to orchestrate your Kubernetes Cluster it gets even better. Kubernetes Deployments = Spinnaker Spinnaker Cluster, which contains Spinnaker Server Groups. Welcome to the world of continuous deployment! :)
– Lennart Blom
Nov 12 at 11:54
add a comment |
up vote
-1
down vote
A deployment contains a single pod template, and generates one replicaset per revision
add a comment |
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
2
down vote
It is meant to be a deployment of each microservice.
You can also manage the quantity of "deployed services" of each microservices type.
So for instance, if you want to deploy Service A (Docker image with an Java service) 5 times, you have a deployment resulting 5 pods. Each pod contains the image of Service A.
If you deploy a new version of this Service A (Docker image with an Java service), Kubernetes is able to do a rolling update and manage the shut down of the old Java service type (the existing pods) and creates 5 new pods with the new Java Service A.2 (a new docker image).
Thus your whole microservices application/infrastructure is build upon multiple deployments. Each generating Kubernetes pods, which are published by Kubernetes services.
Well, the name Deployment is unfortunate, but at least it makes sense that you can upgrade a microservice
– HashRocketSyntax
Nov 12 at 11:22
Yup... but be warned. If you start adding Spinnaker.io to orchestrate your Kubernetes Cluster it gets even better. Kubernetes Deployments = Spinnaker Spinnaker Cluster, which contains Spinnaker Server Groups. Welcome to the world of continuous deployment! :)
– Lennart Blom
Nov 12 at 11:54
add a comment |
up vote
2
down vote
It is meant to be a deployment of each microservice.
You can also manage the quantity of "deployed services" of each microservices type.
So for instance, if you want to deploy Service A (Docker image with an Java service) 5 times, you have a deployment resulting 5 pods. Each pod contains the image of Service A.
If you deploy a new version of this Service A (Docker image with an Java service), Kubernetes is able to do a rolling update and manage the shut down of the old Java service type (the existing pods) and creates 5 new pods with the new Java Service A.2 (a new docker image).
Thus your whole microservices application/infrastructure is build upon multiple deployments. Each generating Kubernetes pods, which are published by Kubernetes services.
Well, the name Deployment is unfortunate, but at least it makes sense that you can upgrade a microservice
– HashRocketSyntax
Nov 12 at 11:22
Yup... but be warned. If you start adding Spinnaker.io to orchestrate your Kubernetes Cluster it gets even better. Kubernetes Deployments = Spinnaker Spinnaker Cluster, which contains Spinnaker Server Groups. Welcome to the world of continuous deployment! :)
– Lennart Blom
Nov 12 at 11:54
add a comment |
up vote
2
down vote
up vote
2
down vote
It is meant to be a deployment of each microservice.
You can also manage the quantity of "deployed services" of each microservices type.
So for instance, if you want to deploy Service A (Docker image with an Java service) 5 times, you have a deployment resulting 5 pods. Each pod contains the image of Service A.
If you deploy a new version of this Service A (Docker image with an Java service), Kubernetes is able to do a rolling update and manage the shut down of the old Java service type (the existing pods) and creates 5 new pods with the new Java Service A.2 (a new docker image).
Thus your whole microservices application/infrastructure is build upon multiple deployments. Each generating Kubernetes pods, which are published by Kubernetes services.
It is meant to be a deployment of each microservice.
You can also manage the quantity of "deployed services" of each microservices type.
So for instance, if you want to deploy Service A (Docker image with an Java service) 5 times, you have a deployment resulting 5 pods. Each pod contains the image of Service A.
If you deploy a new version of this Service A (Docker image with an Java service), Kubernetes is able to do a rolling update and manage the shut down of the old Java service type (the existing pods) and creates 5 new pods with the new Java Service A.2 (a new docker image).
Thus your whole microservices application/infrastructure is build upon multiple deployments. Each generating Kubernetes pods, which are published by Kubernetes services.
answered Nov 10 at 22:58
Lennart Blom
16211
16211
Well, the name Deployment is unfortunate, but at least it makes sense that you can upgrade a microservice
– HashRocketSyntax
Nov 12 at 11:22
Yup... but be warned. If you start adding Spinnaker.io to orchestrate your Kubernetes Cluster it gets even better. Kubernetes Deployments = Spinnaker Spinnaker Cluster, which contains Spinnaker Server Groups. Welcome to the world of continuous deployment! :)
– Lennart Blom
Nov 12 at 11:54
add a comment |
Well, the name Deployment is unfortunate, but at least it makes sense that you can upgrade a microservice
– HashRocketSyntax
Nov 12 at 11:22
Yup... but be warned. If you start adding Spinnaker.io to orchestrate your Kubernetes Cluster it gets even better. Kubernetes Deployments = Spinnaker Spinnaker Cluster, which contains Spinnaker Server Groups. Welcome to the world of continuous deployment! :)
– Lennart Blom
Nov 12 at 11:54
Well, the name Deployment is unfortunate, but at least it makes sense that you can upgrade a microservice
– HashRocketSyntax
Nov 12 at 11:22
Well, the name Deployment is unfortunate, but at least it makes sense that you can upgrade a microservice
– HashRocketSyntax
Nov 12 at 11:22
Yup... but be warned. If you start adding Spinnaker.io to orchestrate your Kubernetes Cluster it gets even better. Kubernetes Deployments = Spinnaker Spinnaker Cluster, which contains Spinnaker Server Groups. Welcome to the world of continuous deployment! :)
– Lennart Blom
Nov 12 at 11:54
Yup... but be warned. If you start adding Spinnaker.io to orchestrate your Kubernetes Cluster it gets even better. Kubernetes Deployments = Spinnaker Spinnaker Cluster, which contains Spinnaker Server Groups. Welcome to the world of continuous deployment! :)
– Lennart Blom
Nov 12 at 11:54
add a comment |
up vote
-1
down vote
A deployment contains a single pod template, and generates one replicaset per revision
add a comment |
up vote
-1
down vote
A deployment contains a single pod template, and generates one replicaset per revision
add a comment |
up vote
-1
down vote
up vote
-1
down vote
A deployment contains a single pod template, and generates one replicaset per revision
A deployment contains a single pod template, and generates one replicaset per revision
answered Nov 10 at 22:40
Jordan Liggitt
6,6262421
6,6262421
add a comment |
add a comment |
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53244033%2fkubernetes-can-a-deployment-have-multiple-replicasets%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
A deployment per microservice is common; a real application might be made of several related Deployments and Services that point at their Pods.
– David Maze
Nov 10 at 22:44