Which of the following changes should the engineer make lo the file to improve container security?
A cloud engineer is reviewing the following Dockerfile to deploy a Python web application:
Which of the following changes should the engineer make lo the file to improve container security?
A . Add the instruction "JSER nonroot.
B . Change the version from latest to 3.11.
C . Remove the EHTRYPOIKT instruction.
D . Ensure myapp/main.pyls owned by root.
Answer: A
Explanation:
To improve container security, the engineer should add the instruction "USER nonroot" to the Dockerfile. This change ensures that the container does not run as the root user, which reduces the risk of privilege escalation attacks. Running containers as a non-root user is a best practice for enhancing security in containerized environments.
Reference: CompTIA Cloud+ content includes security concerns, measures, and concepts for cloud operations, highlighting container security best practices such as running containers with least privilege to mitigate security risks.
Latest CV0-004 Dumps Valid Version with 213 Q&As
Latest And Valid Q&A | Instant Download | Once Fail, Full Refund