Preparing Practice Exam…
Please wait a moment while the system generates the exam questions, answers, and study session.
Please wait a moment while the system generates the exam questions, answers, and study session.
Microsoft Certified: DevOps Engineer Expert · Microsoft
Select one answer.
Written by other learners. Comments can disagree with the marked answer — check the official documentation when in doubt.
whitesource bolt, now mend bolt, is used for package management.
The correct answer is: C. npm install To ensure that only production dependencies are scanned by WhiteSource Bolt, you should install only the production dependencies of your Node.js application. This can be done by running: npm install --only=production This command installs only the dependencies listed under "dependencies" in your package.json file, skipping those listed under "devDependencies", which are only used during development. A. npm edit: Opens a package’s package.json in the default text editor; it does not install or update dependencies. B. npm publish: Publishes the package to the npm registry, making it publicly available; it does not affect dependency installation. D. npm update: Updates installed dependencies but does not limit them to production-only. Therefore, C. npm install --only=production is the command to run.
The npm install command will install the devDependencies along other dependencies when run inside a package directory, in a development environment (the default). Use npm install --only=prod (or --only=production) to install only dependencies, and not devDependencies,regardless of the value of the NODE_ENV environment variable. https://stackoverflow.com/questions/9268259/how-do-you-prevent-install-of-devdependencies-npm-modules-for-node-js-package