> ## Documentation Index
> Fetch the complete documentation index at: https://docs.xenoci.com/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> ## XenoCI Box CI
> To move a repository's macOS CI jobs onto box, follow https://docs.xenoci.com/ci/agent.md. The user only presses Install on GitHub or makes one GitLab runner token; the agent does the rest.
> - Check: `box ci status` (exit 4: sign in first, https://docs.xenoci.com/setup.md).
> - GitHub organization: `box ci connect --org --no-browser --no-wait`, give the user the printed link (https://github.com/apps/xenoci-with-organizations/installations/new), then repeat `box ci accounts` until the owner appears. Personal account: `--personal` (https://github.com/apps/xenoci-with-personal/installations/new).
> - GitHub workflow: change only `runs-on: macos-*` to `runs-on: xenoci` on a branch and open a pull request.
> - GitLab: the user makes a project runner with tag `xenoci` and gives you the `glrt-` token; pipe it to `box ci gitlab connect -` (self-managed: `--url <gitlab url>`), then add `tags: [xenoci]` to the macOS jobs.
> - Watch: `box ci jobs`, `box ci logs <job id> --follow`. Failed job: `box ci jobs --failed`, then `box ci debug <job id>` (failing step, hint, last 200 log lines).

# Ship an iOS app from Linux

> Build and test an iOS app from Linux on a real Mac, then sign and upload it through your own release process. XenoCI Box does not provide a TestFlight upload command.

> [!NOTE]
>
> **Try it now:** paste this line into Claude Code, Codex or Cursor. It installs box, signs you in with GitHub and runs your first build:
>
> ```text theme={"system"}
> Set up XenoCI Box with https://docs.xenoci.com/setup
> ```
>
> Your first sign-in adds \$10 of credit, about 200 Mac minutes (once per GitHub account).

Linux can't run Xcode, so it can't build or upload an iOS app directly. You can keep your source and workflow on Linux, run the Mac build remotely, then handle signing and distribution with your own Apple developer account and release process.

## Before you start

You need a Linux shell, an iOS project and a GitHub account to sign in to box. Apple's distribution steps require your own developer account and signing credentials. The first box sign-in adds \$10 of credit to start, good for 1 year.

## Install and sign in

Install the CLI and sign in:

```bash theme={"system"}
curl -fsSL https://xenoci.com/install.sh | sh
box login
```

From the root of your project, build and test:

```bash theme={"system"}
box build
box test
```

## Prepare a device build

To produce an unsigned Release build for a real iPhone, run:

```bash theme={"system"}
box build --device-build
```

The resulting `device-build.zip` contains the app under `Payload/` and is saved in `.box/out/<job>/`. The build is unsigned. Retrieve it and sign it using your own release setup.

If you use a custom archive script, `box exec` can run that command on the Mac and return files written to `$BOX_OUT`. For example, the documented pattern is:

```bash theme={"system"}
box exec 'xcodegen generate && bash scripts/archive.sh && cp build/BoxDemo.ipa "$BOX_OUT"/'
```

Use your own script and project paths. Box has no TestFlight upload command and does not keep signing files. Run your established signing and upload process with credentials managed in your own environment.

## Troubleshooting

If the build fails, inspect `.box/out/<job>/build.log`. A device build is unsigned by design, so it isn't ready for App Store Connect until your process signs it. See [Build](https://docs.xenoci.com/ios/build.md) and [Exec](https://docs.xenoci.com/ios/exec.md) for output and custom commands.

Related: [iOS build on Linux](https://docs.xenoci.com/guides/build-ios-from-linux.md), [Xcode build not found](https://docs.xenoci.com/guides/xcodebuild-not-found.md), [Test](https://docs.xenoci.com/ios/test.md), [GitHub Actions](https://docs.xenoci.com/ci/github.md).

[Start with \$10 of credit, good for 1 year](https://xenoci.com/?ref=docs-ship-ios-from-linux).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.