Skip to content

Configure GitHub Copilot Agent Environment #120

@josecelano

Description

@josecelano

Parent Epic: #112 - Refactor and Improve E2E Test Execution
Depends On: #113 - Create Dependency Installation Package for E2E Tests (Issue 1-1)

Overview

Create a GitHub Actions workflow file (.github/workflows/copilot-setup-steps.yml) that preinstalls all required development dependencies before the Copilot coding agent starts working. This ensures the agent has the same environment as human contributors, improving reliability and speed when working on assigned issues.

Objectives

  • Create .github/workflows/copilot-setup-steps.yml workflow file
  • Configure workflow to build and run dependency-installer binary
  • Install all development dependencies (cargo-machete, OpenTofu, Ansible, LXD)
  • Verify installations are successful
  • Test workflow manually before agent use

Key Components

Workflow Requirements:

  • Job name MUST be copilot-setup-steps (GitHub requirement)
  • Triggers: workflow_dispatch, push, pull_request on workflow file changes
  • Permissions: Minimal (contents: read)
  • Runs on: ubuntu-latest

Workflow Steps:

  1. Checkout code
  2. Set up Rust toolchain
  3. Build dependency-installer binary
  4. Install all dependencies using the binary
  5. Verify installations succeeded

Why Use Our Binary

  • ✅ Consistent with Issue 1-1
  • ✅ Tested (comprehensive tests in Issues 1-1-1 through 1-1-4)
  • ✅ Maintainable (single source of truth)
  • ✅ Idempotent (safe to run multiple times)
  • ✅ Better error handling than bash scripts

Acceptance Criteria

  • Pre-commit checks pass
  • Workflow file created at correct location
  • Workflow runs successfully when triggered manually
  • All dependencies are installed correctly
  • Copilot agent can use the workflow

Time Estimate

2-3 hours

Related Documentation

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions