A

Admin • 828.43K Points
Coach

Q. What is the correct syntax to map ports in docker-compose.yml?

  • (A) port: '80:80'
  • (B) map_ports: '80:80'
  • (C) ports: - '80:80'
  • (D) expose: 80

Explanation by: Admin
The `ports` key is used with a dash and port mapping like `- '80:80'`.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.