Courseiva
Design and implement a source control strategyhardMultiple ChoiceObjective-mapped

AZ-400 Practice Question: Design and implement a source control strategy

Your organization has multiple GitHub repositories that use shared workflows. You want to centrally manage these workflows and ensure they are always up to date. What is the recommended approach?

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

Create a central repository with reusable workflows and reference them using the 'uses' keyword in your workflows.

The recommended approach is to create a central repository with reusable workflows and reference them using the 'uses' keyword. This is a native GitHub Actions feature that allows you to define shared workflow files in one repository and call them from any other repository in your organization. This ensures all workflows stay up to date centrally. The other options are not recommended: B uses API scheduling which is unnecessary and harder to manage; C downloads workflows from blob storage as inline scripts which loses the benefits of shared workflow versioning; D uses Git submodules which are designed for code dependencies and do not integrate well with GitHub Actions workflow execution.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • Create a central repository with reusable workflows and reference them using the 'uses' keyword in your workflows.

    Why this is correct

    Reusable workflows are the official GitHub Actions pattern: you store a workflow file in a central repository and invoke it from other repositories using the `uses` keyword with a path like `owner/repo/.github/workflows/reusable.yml@ref`. This approach supports inputs, secrets, and version pinning, and is the recommended way to avoid duplicating CI/CD logic across many GitHub repositories.

  • Use the GitHub API to push workflow files to each repository on a schedule.

    Why it's wrong here

    Using the GitHub API to programmatically push workflow files to each repository on a schedule is not recommended because it introduces high maintenance overhead, requires secure credentials for every repo, and can silently fail or create drift between repositories. It also bypasses the native versioning and audit trail of Git, making it a fragile and non-standard solution for sharing workflows.

  • Download the workflows from a central blob storage and include them as inline scripts.

    Why it's wrong here

    Downloading workflow files from central blob storage and including them as inline scripts is not a supported pattern for workflow reuse. GitHub Actions executes steps inside a repository checkout; fetching external blobs at runtime is not equivalent to a reusable workflow and cannot leverage native features like workflow-level inputs, concurrency, or proper logging, so it is both unmaintainable and incorrect.

  • Store the workflows in a separate repository and use Git submodules to include them.

    Why it's wrong here

    Using Git submodules to include workflow files is not a valid reuse mechanism because GitHub Actions only discovers workflow files in the `.github/workflows` directory of the base repository, and submodules are not checked out by default unless explicitly configured. Even when configured, submodules are intended for code dependencies, not for sharing Action workflow definitions, and this approach does not integrate with the reusable workflow engine.

About these practice questions

Courseiva writes every AZ-400 question from scratch — 823 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This AZ-400 practice question is part of Courseiva's free Microsoft certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the AZ-400 exam.