nerdexam
Docker

DCA · Question #55

What is the docker command to setup a swarm?

The correct answer is A. docker swarm init. This question asks for the correct Docker command to set up and initialize a new Docker Swarm.

Submitted by tom_us· Apr 18, 2026Container Orchestration

Question

What is the docker command to setup a swarm?

Options

  • Adocker swarm init
  • Bdocker swarm create
  • Cdocker init swarm
  • Ddocker create swarm

How the community answered

(16 responses)
  • A
    88% (14)
  • C
    6% (1)
  • D
    6% (1)

Why each option

This question asks for the correct Docker command to set up and initialize a new Docker Swarm.

Adocker swarm initCorrect

The `docker swarm init` command is specifically used to initialize a new Docker Swarm on the current node, designating it as the first manager node.

Bdocker swarm create

`docker swarm create` is not a valid command for initializing a Docker Swarm.

Cdocker init swarm

The command syntax is incorrect; `init` is a subcommand of `docker swarm`, so the order is reversed.

Ddocker create swarm

The command syntax is incorrect; `create` is not the correct subcommand for Swarm initialization.

Concept tested: Docker Swarm initialization

Source: https://docs.docker.com/engine/reference/commandline/swarm_init/

Topics

#Docker Swarm#Swarm initialization#CLI command#Orchestration setup

Community Discussion

No community discussion yet for this question.

Full DCA Practice