0
0
Dockerdevops~10 mins

Service scaling in Docker - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the command to scale the service named webapp to 3 replicas.

Docker
docker service scale webapp=[1]
Drag options to blanks, or click blank then click option'
A4
B2
C3
D1
Attempts:
3 left
💡 Hint
Common Mistakes
Using a number less than 1, which stops the service.
Forgetting the equal sign.
2fill in blank
medium

Complete the command to list all running services and their replicas.

Docker
docker service [1]
Drag options to blanks, or click blank then click option'
Als
Bps
Clist
Dshow
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'ps' which shows tasks, not services.
Using 'show' which is not a valid docker service command.
3fill in blank
hard

Fix the error in the command to scale the service api to 5 replicas.

Docker
docker service scale [1]=5
Drag options to blanks, or click blank then click option'
Aservice-api
Bapi
Capi-service
Dapis
Attempts:
3 left
💡 Hint
Common Mistakes
Adding extra words to the service name.
Using plural or hyphenated names incorrectly.
4fill in blank
hard

Fill both blanks to create a command that updates the frontend service to have 4 replicas.

Docker
docker service update --replicas [1] [2]
Drag options to blanks, or click blank then click option'
A4
Bfrontend
Cwebapp
D--force
Attempts:
3 left
💡 Hint
Common Mistakes
Using the wrong service name.
Putting the service name before the replicas number.
5fill in blank
hard

Fill all three blanks to write a command that forces update on the backend service and scales it to 6 replicas.

Docker
docker service update [1] [2] [3]
Drag options to blanks, or click blank then click option'
A--force
B--replicas
C6
Dbackend
Efrontend
Attempts:
3 left
💡 Hint
Common Mistakes
Mixing service names.
Forgetting the --force flag.