Skip to content

Commit 1c21115

Browse files
authored
Merge pull request docker#10302 from iwpnd/master
fixed formatting in swarm-deploy.md
2 parents 1069a31 + 0f9158f commit 1c21115

1 file changed

Lines changed: 12 additions & 11 deletions

File tree

get-started/swarm-deploy.md

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -26,19 +26,20 @@ Swarm never creates individual containers like we did in the previous step of th
2626

2727
Let's write a simple stack file to run and manage our bulletin board. Place the following in a file called `bb-stack.yaml`:
2828

29-
```yaml
30-
version: '3.7'
31-
32-
services:
33-
bb-app:
34-
image: bulletinboard:1.0
35-
ports:
36-
- "8000:8080"
37-
```
3829

39-
In this Swarm YAML file, we have just one object: a `service`, describing a scalable group of identical containers. In this case, you'll get just one container (the default), and that container will be based off of your `bulletinboard:1.0` image created in [Part 2](part2.md) of the Quickstart tutorial. In addition, We've asked Swarm to forward all traffic arriving at port 8000 on our development machine to port 8080 inside our bulletin board container.
30+
```yaml
31+
version: '3.7'
32+
33+
services:
34+
bb-app:
35+
image: bulletinboard:1.0
36+
ports:
37+
- "8000:8080"
38+
```
39+
40+
In this Swarm YAML file, we have just one object: a `service`, describing a scalable group of identical containers. In this case, you'll get just one container (the default), and that container will be based off of your `bulletinboard:1.0` image created in [Part 2](part2.md) of the Quickstart tutorial. In addition, We've asked Swarm to forward all traffic arriving at port 8000 on our development machine to port 8080 inside our bulletin board container.
4041

41-
> **Kubernetes Services and Swarm Services are very different!** Despite the similar name, the two orchestrators mean very different things by the term 'service'. In Swarm, a service provides both scheduling _and_ networking facilities, creating containers and providing tools for routing traffic to them. In Kubernetes, scheduling and networking are handled separately: _deployments_ (or other controllers) handle the scheduling of containers as pods, while _services_ are responsible only for adding networking features to those pods.
42+
> **Kubernetes Services and Swarm Services are very different!** Despite the similar name, the two orchestrators mean very different things by the term 'service'. In Swarm, a service provides both scheduling _and_ networking facilities, creating containers and providing tools for routing traffic to them. In Kubernetes, scheduling and networking are handled separately: _deployments_ (or other controllers) handle the scheduling of containers as pods, while _services_ are responsible only for adding networking features to those pods.
4243

4344
## Deploy and check your application
4445

0 commit comments

Comments
 (0)