advancedTop 100 Interview Questions

What does `--cap-drop=ALL` followed by selectively adding capabilities back accomplish?

It follows the principle of least privilege at the Linux capability level — instead of granting a container the default broad capability set, you drop everything and re-add only the specific capabilities the application actually needs, minimizing what a compromised process could do.

This is a Pro chapter

Sign in, then upgrade to Pro or Power to unlock this and the full DevOps Mastery library.

What does `--cap-drop=ALL` followed by selectively adding capabilities back accomplish?

Next Step

Continue to Why are container logs ephemeral by default, and what's the production implication?← Back to all Docker questions