About security_opt in docker-compose

security_opt🔗
Override the default labeling scheme for each container.

security_opt:

  • label:user:USER
  • label:role:ROLE

Above is the description of security_opt in docker-compose document. but I still dont know how to use the security_opt in docker-compose.yml, please give me an example. thank you.
and what is labeling scheme of container?

1 Like