nerdexam
Docker

DCA · Question #113

Will this command ensure that overlay traffic between service tasks is encrypted? Solution: docker service create --network --encrypted

The correct answer is B. No. The docker service create command does not have an --encrypted flag to enable overlay traffic encryption; this setting must be applied when the overlay network itself is created.

Submitted by hassan_iq· Apr 18, 2026Security

Question

Will this command ensure that overlay traffic between service tasks is encrypted? Solution: docker service create --network --encrypted

Options

  • AYes
  • BNo

How the community answered

(38 responses)
  • A
    5% (2)
  • B
    95% (36)

Why each option

The `docker service create` command does not have an `--encrypted` flag to enable overlay traffic encryption; this setting must be applied when the overlay network itself is created.

AYes

The `--encrypted` flag is not a valid option for `docker service create` to enable network encryption.

BNoCorrect

The `docker service create` command does not have an `--encrypted` flag to enable encryption for network traffic. Overlay network encryption is enabled by adding the `--opt encrypted` flag to the `docker network create` command, and services then join this pre-configured encrypted network.

Concept tested: Docker Swarm service network encryption

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

Topics

#Docker Swarm#Overlay Networks#Network Encryption#docker service command

Community Discussion

No community discussion yet for this question.

Full DCA Practice