Microsoft AZ-400 Practice Test - Questions Answers, Page 37
List of questions
Question 361

You have a project in Azure DevOps named Project1.
You need to ensure that all new pipelines in Project1 execute three specific tasks during pipeline execution. What should you create?
Explanation:
Question 362

You plan to create a GitHub workflow that will use GitHub Actions. The actions will require a 256-KB secret. You need to recommend a solution to store and encrypt the secret. The secret value must be accessible only to the workflow. The solution must minimize administrative effort What should you recommend?
Explanation:
https://docs.github.com/en/actions/security-guides/encrypted-secrets "To use secrets that are larger than 48 KB, you can use a workaround to store encrypted secrets in your repository and save the decryption passphrase as a secret on GitHub." Because it requires less administrative privilege it's at repository level
Question 363

You have a pipeline named Pipeline1 in Azure Pipelines.
You need to create a service connection to enable Pipeline1 to download a public container image.
Which type of service connection should you create?
Question 364

DRAG DROP
You have an Azure DevOps pipeline that is used to deploy a Node.js app.
You need to ensure that the dependencies are cached between builds.
How should you configure the deployment YAML? To answer, drag the appropriate values to the correct targets. Each value may be used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to view content.
NOTE Each correct selection is worth one point.
Question 365

HOTSPOT
You are designing YAML-based Azure pipelines for the apps shown in the following table
You need to configure the YAML strategy value for each app. The solution must minimize app downtime. Which value should you configure for each app? To answer, select the appropriate options in the answer area.
Explanation:
App1 Canary
App2 rolling
App1 Canary would minimize app downtime for the first app, as it would only deploy new code when the canary has confirmed that it is functional - and if there are any issues, it would roll back to the previous version of the code.
App2 rolling would be the second option, as it would allow for frequent deployments of new code, while still giving the developers enough time to fix any issues that may have been introduced during new code deployments.
Question 366

DRAG DROP
You use get get for source control.
You delete a file, commit the changes, and continue to work.
You need to recover the deleted file.
Which three commands should you run in sequence? To answer, move the appropriate commands from the list of commands to the answer area and arrange them in the correct order.
Question 367

DRAG DROP
You have an app named App1. You have a Log Analytics workspace named Workspace 1 that contains two tables named Events and Logs. Appl manages events in multiple locations and writes logs to Workspace1. You need to query Workspace1 for all log entries related to Asia that occurred during the last two days. In which order should you arrange the query statements? To answer, move all statements from the list of statements to the answer area and arrange them in the correct order.
Question 368

DRAG DROP
You are using the Dependency Tracker extension in a project in Azure DevOps.
You generate a risk graph for the project.
What should you use in the risk graph to identify the number of dependencies and the risk level of the project? To answer, drag the appropriate elements to the correct data points. Each element may be used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to view content.
NOTE: Each correct selection is worth one point.
Question 369

DRAG DROP
You are creating a container for an ASP.NET Core app.
You need to create a Dockerfile file to build the image. The solution must ensure that the size of the image is minimized How should you configure the file? To answer, drag the appropriate values to the correct targets.
Each value may be used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to view content. NOTE: Each correct selection is worth one point.
Question 370

HOTSPOT
You have a virtual machine that runs Windows Server 2019 and is managed by using Desired State Configuration (DSC). You have the following DSC configuration.
You have the following Local Configuration Manager (LCM) configuration.
For each of the following statements, select Yes if the statement is true. Otherwise, select No.
NOTE: Each correct selection is worth one point.
Question