Back to blog
TutorialiOSCI/CDGitHub ActionsXcode
iOS CI/CD with GitHub Actions on Bare-Metal Mac
April 8, 202610 min readby Macyou Team
If you've ever waited 45 minutes for a macOS GitHub Actions runner to build your iOS app, you know the pain. In this guide, we'll set up a self-hosted runner on a Macyou M4 Pro server — cutting build times by 3–5x.
Why Self-Hosted?
GitHub's hosted macOS runners use older hardware and are shared. Self-hosted on bare-metal M4 Pro means: 14-core CPU for parallel builds, dedicated resources (no noisy neighbors), persistent caches (DerivedData stays between builds), and full control over Xcode versions.
Step 1: Deploy and Configure
$ macyou deploy --chip m4-pro --ram 48 --stack clean-macos
$ ssh root@YOUR_IP
$ xcode-select --installStep 2: Install the GitHub Runner
$ mkdir actions-runner && cd actions-runner
$ curl -o actions-runner.tar.gz -L \
https://github.com/actions/runner/releases/download/v2.321.0/actions-runner-osx-arm64-2.321.0.tar.gz
$ tar xzf actions-runner.tar.gz
$ ./config.sh --url https://github.com/YOUR_ORG/YOUR_REPO \
--token YOUR_TOKEN --labels macyou-m4-pro
$ ./svc.sh install && ./svc.sh startStep 3: Update Your Workflow
# .github/workflows/ios-build.yml
jobs:
build:
runs-on: [self-hosted, macyou-m4-pro]
steps:
- uses: actions/checkout@v4
- name: Build
run: xcodebuild -scheme MyApp -sdk iphoneos
- name: Deploy to TestFlight
run: fastlane betaResults
Typical results after switching from GitHub-hosted to Macyou self-hosted: build time drops from 38 minutes to 8 minutes, with DerivedData caching cutting subsequent builds to under 4 minutes.