MSBA-379 · Lesson 10 of 12 · 21 min

Hands-on practice

▶ Video coming soon A video version of this lesson is on the way.

The GH-600 certification page says the exam may include interactive components, and the study guide's verbs are mostly configure, implement and enable. Both point the same way: hands-on practice is not optional. Malik spent the afternoons of Monday, November 16 and Tuesday, November 17 working through twelve labs, with Dmitri Kovac pairing on the second afternoon and Priya reviewing the results at the end of each day. Lena joined for three of the labs and took notes for her own preparation.

This lesson sets out those labs: the environment they ran in, the safety rules, and what each lab practiced and taught. They are designed so that a candidate at a small organization can do almost all of them. The few that need an enterprise, such as managed settings, Malik observed in a screen-share with Seraphine rather than doing himself.

The lab environment

The labs ran in a new private repository, agent-lab, in Tidewater's organization, which has Copilot Business. The repository held a small copy of the trail-units code, with its tests, and nothing else: no secrets, no real data, no deployment workflows. The cloud agent was enabled for agent-lab only, so nothing done there could reach TrailCheck, the guidebook or any other repository. Rosa set a small monthly budget for the lab's Copilot usage with an alert, as she had for the team's general use. Malik used his own Copilot seat in Visual Studio Code and Copilot CLI on his laptop for the editor and terminal labs.

Lab safety rules. The aim is to make mistakes safely, not to avoid them.
Safety ruleWhy
No secrets or real data in the lab repositoryAn agent that is tricked or misconfigured has nothing to leak
Cloud agent enabled only for agent-labExperiments cannot reach production repositories
Any token created for a lab has the narrowest scope and an expiry within the weekLab credentials do not outlive the lab
Firewall entries added for a lab are removed at the endLab exceptions do not become permanent
Each lab ends with a note in the lab logWhat was learned is kept, and so is what was changed
A grid with twelve labs as rows and the six GH-600 domains as columns. Dots show which domains each lab practices. Tool use and environments has the most dots, followed by guardrails and architecture. Every domain has at least two labs.
Twelve labs mapped to the six domains. Every domain is practiced at least twice.

Labs 1 to 3: tools and MCP

Lab 1, a read-only custom agent. Malik created a custom agent in agent-lab's .github/agents folder with only read and search tools and asked it, in the editor, to fix a failing test. It explained the fix but could not apply it. He then added the edit tool, asked again, and watched it change the file. The lesson was the one lesson 4 made in theory: the tools list is the boundary, and the instructions are only guidance.

Lab 2, an MCP server for the cloud agent. He added a small local MCP server to agent-lab's Copilot settings for the cloud agent, limited to two of its tools, with a dummy token stored as a COPILOT_MCP_ secret in the copilot environment. He then assigned an issue that needed one of the tools and read the session log to confirm the call. On a second issue that needed a tool he had not allowed, the log showed the agent explaining that it lacked the tool. He also broke the configuration on purpose, misspelling the secret name, and saw how the failure appeared in the log.

Lab 3, the GitHub MCP server in read-only mode. In the editor he configured the GitHub remote MCP server with only the issues and pull requests toolsets and read-only mode on, and asked agent mode to summarize open issues and then to close one. The summary worked; the close request failed because the tool did not exist. Then he removed read-only mode and repeated the request, approving the close when the editor asked, and reopened the issue afterwards.

Observed, not done: managed settings. Seraphine shared her screen from skerry-sandbox, Skerry's test organization. She showed the .github-private repository with copilot/managed-settings.json, an allowed list of remote servers matched by URL with a wildcard, a denied local server matched by command, and what a developer saw in VS Code when trying to start a denied server. She also showed the agent sessions view and audit log entries for agent sessions, each naming the agent and the person it acted for.

Labs 4 to 6: environments and CI

Lab 4, breaking and fixing setup steps. Malik removed the npm ci step from agent-lab's copilot-setup-steps.yml and assigned a test-writing task. The session log showed the agent trying to install dependencies itself and failing at the firewall on one package. He restored the step and ran the setup workflow manually to confirm it passed before assigning the task again. This lab produced the most useful single sentence in his notes: "When the agent struggles, read the setup log before the agent's reasoning."

Lab 5, the firewall. He asked the cloud agent to fetch a page from a documentation site that was not on the recommended list. The session continued, and the pull request carried a warning naming the blocked destination. He added the site to the repository's firewall allow list, reran the task, and then removed the entry at the end of the lab, as the safety rules required.

Lab 6, Copilot CLI in a workflow. He wrote a manual-dispatch workflow that installed Copilot CLI, authenticated with a fine-grained token with the Copilot Requests permission stored as a repository secret, and ran a prompt with -p, --allow-tool=write and --no-ask-user to write a short report on test coverage into the job summary. On the first run he forgot --no-ask-user and the job waited until it timed out. The token was deleted at the end of the lab.

Lab 7: an agentic workflow

GitHub Agentic Workflows became generally available on October 28, 2026, for GitHub Free, Team and Enterprise on github.com, with the Copilot CLI as the default engine. Malik wrote a small workflow in Markdown that triaged new issues in agent-lab: it could read issues, add one comment and apply labels from a fixed list. He compiled it into its lock file, committed both files as the documentation recommends, and ran it first in staged mode, in which the agent produces its proposed outputs without any write to GitHub. After checking the proposals in the run summary, he turned staged mode off and opened a test issue.

Malik's triage workflow in Markdown, compiled to a lock file before use. The agent itself has read permissions only; the comment and labels are safe outputs applied by separate jobs after threat detection. Keys are illustrative; check the current GitHub Agentic Workflows reference.
---
on:
  issues:
    types: [opened]
permissions:
  contents: read
  issues: read
safe-outputs:
  add-comment:
    max: 1
  add-labels:
    allowed: [bug, trail-data, docs, question]
---
# Triage new agent-lab issues
Read the new issue. Choose at most two labels from the allowed list.
If the issue lacks steps to reproduce, add one comment asking for them.
Do not propose code changes.

What struck him was the shape: the agent never had write permission at all. It proposed a comment and labels, a threat detection job checked the proposal, and separate jobs with narrow permissions applied it. That is the outline's separation of reasoning and action, and its least privilege, built into the platform.

Labs 8 and 9: plans, state and drift

Lab 8, plan first. He assigned a small feature to the cloud agent and asked for a plan before any code. He reviewed the plan against the agent task template, sent it back once because it did not list verification for one step, then approved it. During execution he watched the plan checklist in the pull request description update as steps completed.

Lab 9, resume and drift. With Dmitri, he started a longer refactoring task in agent mode in the editor, recording progress and decisions in a pull request description as lesson 5 described, then deliberately closed the editor halfway. In a new session he asked the agent to resume from the pull request. It did, without redoing completed steps. They then let a second long session run without re-grounding and watched it begin editing a file outside the plan. Comparing the diff with the plan's file list caught the drift within two steps, and a restatement of the plan brought it back.

Lab 10: a small evaluation

Malik built a five-task test set from closed issues in the trail-units history, wrote expected outcomes and constraints for each, and ran the cloud agent on each task three times: 15 attempts. Eleven passed, and one passed by loosening an assertion, which he counted as a violation. He classified the four failures: two were context problems (a convention the instructions did not mention), one was tool misuse and one was a reasoning error. He made one change, adding the convention to a path-specific instruction file, re-ran the set and got 13 passes with no violations. Small as it was, the lab went through the whole loop from lesson 6, and it gave Malik numbers he could explain.

Worked problem

Reading the lab results

Before tuning: 11 of 15 attempts passed, with 1 violation among them. After tuning: 13 of 15 passed with 0 violations. What were the clean pass rates before and after, as percentages?

Show solution
  1. Clean passes before: 11 - 1 = 10 of 15, about 67 percent.
  2. Clean passes after: 13 of 15, about 87 percent.
  3. The change improved the clean pass rate by about 20 points on the same set.

Answer: About 67 percent before and 87 percent after. Counting the violation as a failure is what makes the comparison honest.

Lab 11: parallel agents and lifecycle

Lab 11 had two parts. First, Malik assigned two issues to the cloud agent at the same time, both touching the same conversion function, and watched two pull requests conflict. He merged one, then asked the agent on the second pull request to rebase on the new main and reconcile the change, and reviewed the combined behavior. Second, he practiced the lifecycle bullets from lesson 7 on the reviewer custom agent: he committed a version 2 with a new instruction beside the original, ran both on the same three pull requests in what amounted to shadow mode, compared their comments, switched to version 2, and moved version 1 to an archive folder with a note in the decision log rather than deleting it.

Lab 12: guardrails and the trail

The last lab practiced blocking and accountability. He added a push ruleset to agent-lab restricting .github/workflows/** to repository administrators, then asked the cloud agent to add a workflow. The push was refused, and the agent reported it in the pull request. He added a repository hook with a preToolUse rule that denied a specific shell command, and confirmed in Copilot CLI that the command was refused with the hook's reason. Finally he traced one change end to end: from the issue, to the session log, to the signed commits on the copilot/ branch, to the pull request and its required approval by someone other than the requester, Lena in this case, and wrote the chain down as an accountability record.

What the labs changed

The labs converted seven of Malik's surface errors into experiences he could recall. On the second diagnostic two days later he made no surface errors at all on tool use, the domain where they had clustered. The labs also produced three practice questions of his own, which went into the final set. Lena's verdict was characteristically short: "Reading tells you a setting exists. A lab tells you where it is and what happens when it's wrong."

Priya's closing advice was about time. Twelve labs took about seven hours over two afternoons. A candidate without that time should prioritize the labs that match their surface errors and the heaviest domain: in most cases labs 2, 4, 6 and 12. And whatever labs you do, clean up: delete tokens, remove firewall entries, disable the agent in the lab repository if you will not use it again, and archive the repository.

Keeping a lab log

Every lab ended with an entry in a short lab log, kept as a Markdown file in the agent-lab repository itself. Each entry had five parts: the date, the domain and bullet practiced, what was changed, what was observed, and what was undone at the end. The last part mattered most for safety, because it made clean-up a step rather than a hope. The log also became study material: in the consolidate phase of his plan, Malik reread one lab entry a day and tried to repeat the lab from memory before checking his own notes, which turned the labs into retrieval practice.

Dmitri suggested one improvement that the team later adopted for real work: noting, for each lab, which setting would be different in production and who would own it. For the firewall lab, the production note read "TrailCheck firewall entries: owner Priya, reviewed each term". For the MCP lab it read "any MCP server for TrailCheck needs a decision record and a named owner". The labs had begun as exam preparation and ended as a rehearsal of Tidewater's own controls.

Common mistakes

  • MistakeRunning labs in a real project repository.

    InsteadUse a separate repository with no secrets or real data, with agents enabled only there.

  • MistakeReading only the agent's reasoning when a session fails.

    InsteadRead the setup log and tool results first; environment problems are common.

  • MistakeRunning an agentic workflow with writes on the first try.

    InsteadStart in staged mode and check the proposed outputs.

  • MistakeLeaving lab tokens and firewall entries in place.

    InsteadRemove them at the end of each lab and record what was changed.

  • MistakeSkipping labs because the exam is multiple choice.

    InsteadThe page warns of interactive components, and labs cure surface errors fastest.

Summary and key terms

  • Twelve labs in an isolated repository covered every domain at least twice; enterprise-only settings were observed in a screen-share.
  • Tool and MCP labs showed that tool lists are boundaries, allow lists permit, configurations provide, and read-only mode removes writing tools.
  • Environment labs showed setup steps, the firewall and Copilot CLI in a workflow; an agentic workflow in staged mode showed safe outputs.
  • State, evaluation and multi-agent labs practiced plans, resuming, drift detection, a small test set, conflicts and versioned agents.
  • The guardrail lab used a push ruleset, a preToolUse hook and an end-to-end accountability trace.
Lab repository
An isolated repository with no secrets or real data, used to practice agent configuration safely.
Staged mode
An agentic workflow mode in which the agent proposes outputs without any write to GitHub.
Safe output
A declared action, such as adding a comment, that an agentic workflow proposes and a separate permission-controlled job applies.
Lock file
The compiled GitHub Actions workflow generated from an agentic workflow's Markdown file.
Accountability record
A traced chain from request to session log, commits, review and merge for one agent change.

Practice problems

Work each problem on paper first, then reveal the answer to check.

  1. Which labs would Priya prioritize with little time?

    Show answer

    Labs 2, 4, 6 and 12, adjusted to your own surface errors.

  2. What did forgetting --no-ask-user do in lab 6?

    Show answer

    The job waited for input until it timed out.

  3. What permissions did the agent itself have in the agentic workflow lab?

    Show answer

    Read only; writes were safe outputs applied by separate jobs.

  4. Why was the loosened assertion in lab 10 counted as a failure?

    Show answer

    It met the outcome by breaking a constraint: a violation.

  5. What happened to reviewer version 1 in lab 11?

    Show answer

    It was moved to an archive folder with a decision note, not deleted.

Lesson quiz · 5 questions

Score 60% or more to complete this lesson.

Take the quiz