Azure DevOps Engineer Question 27
Why It Matters
Ensuring artifacts contain only binaries prevents source leakage and streamlines deployments, directly impacting security and operational efficiency.
Key Takeaways
- •Use .NET Core CLI publish task to generate deployment artifact.
- •Artifact contains only compiled binaries and config, excludes source code.
- •Copy Files task would incorrectly include entire source repository.
- •Archive Files task without build yields no compiled output.
- •Publish Build Artifacts task alone cannot filter out source files.
Summary
The video walks through AZ‑400 question 27, which asks which Azure Pipelines task should be used to create a deployment artifact for a .NET application that must contain only compiled binaries and configuration files, not source code.
It explains that the .NET Core CLI task with the publish command compiles the project, places the output in the publish folder, and automatically excludes source files. This task therefore satisfies the requirement for a clean, deploy‑ready artifact.
The presenter dismisses the other options: the Copy Files task would copy the entire repository, the Archive Files task would package unbuilt source, and the Publish Build Artifacts task alone cannot filter out source code. These explanations reinforce the standard .NET CI/CD pattern.
Choosing the correct task reduces artifact size, improves security by not exposing source, and aligns with Microsoft’s recommended pipeline design—critical for both exam success and production deployments.
Comments
Want to join the conversation?
Loading comments...