Getting Started

The GetMac Buildkite Plugin provisions ephemeral macOS virtual machines on GetMac Cloud for your CI/CD jobs. Each Buildkite job gets a fresh macOS VM that is automatically created before the build and deleted after it completes.

Prerequisites

  • Active GetMac account (free tier available)
  • GetMac API key from the dashboard
  • Buildkite agent running on your machine
  • curl, jq, and ssh installed on the agent

Step 1: Set API Key

Set the GETMAC_CLOUD_API_KEY environment variable on your Buildkite agent. For security, set this as a Buildkite pipeline environment variable or in an agent environment hook — do not put it in your pipeline YAML.

export GETMAC_CLOUD_API_KEY="your-api-key-here"

Step 2: Configure Pipeline

Add the GetMac plugin to your Buildkite pipeline.yml:

steps:
  - label: ":mac: Build & Test"
    command: "swift test"
    plugins:
      - getmac-io/getmac#main:
          project-id: "your-project-id"

See Configuration for all available plugin parameters.

How It Works

  1. Pre-command — Creates a fresh macOS VM and waits for it to boot.
  2. Command — Establishes an SSH connection and executes your build command on the VM.
  3. Pre-exit — Terminates the VM to clean up resources automatically.

Resources

Getting Started | GetMac