Can you remote build for iOS over the internet?

Hello,

Right now I work on my windows laptop and use the remote build option inside of Unreal to connect to my macbook that’s on my local network.

If my friend who is far away wants to collaborate with me and use my macbook for remote builds is there a way to do that over the internet?

Yes it is possible, following setup assumes you are on windows and wand to use Mac for remote build.

First, you need to setup BuildConfiguration.xml file. (named exactly this way, as shown in bold)

UnrealBuildTool reads settings from this XML config files in the following locations:

  1. Engine/Saved/UnrealBuildTool/BuildConfiguration.xml
  2. User Folder/AppData/Roaming/Unreal/Engine/UnrealBuildTool/BuildConfiguration.xml
  3. My Documents/UnrealEngine/UnrealBuildTool/BuildConfiguration.xml

Second, Please note that you only need one xml config file in one of the above locations, otherwise one file overrides the other and you loose control on what settings are applied

Third, if you built engine from source you should setup a config file once and should not modify it any further, because each time you modify it, the engine code needs to be rebuilt (that will happen without your consent)

if you installed the engine via Epic launcher, then feel free to play around with editing config file in place until settings work. engine won’t be rebuilt, only project files will.

Finaly, the BuildConfiguration.xml file should at the bare minimum contain following elements:
note: following is tested with unreleased UE4.24, engine version and it should probably work with any previous engine version (otherwise you might want to consider building from source to have more control)

<?xml version="1.0" encoding="utf-8"?>
<Configuration xmlns="https://www.unrealengine.com/BuildConfiguration">
  <IOSToolChain>
    <!-- Which version of the iOS SDK to target at build time -->
    <!-- default = latest -->
    <IOSSDKVersion>latest</IOSSDKVersion>
    <!-- Which version of the iOS to allow at build time -->
    <!-- default = 7.0 -->
    <BuildIOSVersion>7.0</BuildIOSVersion>
    <!-- If this is set, then we don't do any post-compile steps except moving the executable into the proper spot on the Mac -->
    <!-- default = false -->
    <bUseDangerouslyFastMode>false</bUseDangerouslyFastMode>
  </IOSToolChain>
  <!-- TODO: unused element, expand elements and input correct values -->
  <!-- Settings for uploading and building on a remote Mac -->
  <RemoteMac>
    <!-- ServerName -->
    <!-- default = ? -->
    <ServerName />
    <!-- The remote username -->
    <!-- default = ? -->
    <UserName />
    <!-- Instead of looking for RemoteToolChainPrivate.key in the usual places (Documents/Unreal Engine/UnrealBuildTool/SSHKeys, Engine/Build/SSHKeys), this private key will be used if set -->
    <!-- default = ? -->
    <SshPrivateKey />
    <!-- The authentication used for Rsync (for the -e rsync flag) -->
    <!-- default = ? -->
    <RsyncAuthentication />
    <!-- The authentication used for SSH (probably similar to RsyncAuthentication) -->
    <!-- default = ? -->
   <SshAuthentication />
  </RemoteMac>
</Configuration>

I think you can omit some elements from RemoteMac element node, but I don’t guarantee that this will work.

For additional options, such as project generation settings and various build settings see below reference:

The above xml sample contains xml commets to help you get started, but note that only IOSToolChain element is set correctly to defaults, and, RemoteMac element and it’s sub elements need to be configured by yourself by giving correct information for UBT to gather.

for example RsyncAuthentication in above code represents empty element and needs to be rewritten to

<RsyncAuthentication>input_valid_value_here</RsyncAuthentication>

you do so for each empty element.

If you find this answer helpful mark is as answered, and fell free to open new question on how to handle configuration files and adjusting specific settings for your local network.

I can give additinoal advice to take a look at UBT source code to troubleshoot problems, because some stuff has been deprecated while other stuff has been added a new.

Here is additional stuff related to your problem to put into xml file to speed up build time (adjust as needed)

  <ParallelExecutor>
    <!-- Processor count multiplier for local execution. Can be below 1 to reserve CPU for other tasks.
    usefull for CPU's with more than 1 thread per core, CPU hyperthreading -->
    <!-- default = 1.0 -->
    <ProcessorCountMultiplier>1.0</ProcessorCountMultiplier>
    <!-- Maximum processor count for local execution.
    number of CPU cores to use -->
    <!-- default = INT_MAX -->
    <MaxProcessorCount>4</MaxProcessorCount>
    <!-- When enabled, will stop compiling targets after a compile error occurs. -->
    <!-- default = false -->
    <bStopCompilationAfterErrors>false</bStopCompilationAfterErrors>
  </ParallelExecutor>
  <!-- Global settings for building. Does not contain any target-specific settings. -->
  <BuildConfiguration>
    <!-- Whether to allow using parallel executor on Windows. -->
    <!-- default = true -->
    <bAllowParallelExecutor>true</bAllowParallelExecutor>
    <!-- Whether to clean Builds directory on a remote Mac before building.
    While building for iOS requires a Mac, using remote compilation means that a whole team that primarily uses Windows machines can build for iOS using one Mac. -->
    <!-- default = false -->
    <bFlushBuildDirOnRemoteMac>false</bFlushBuildDirOnRemoteMac>
  </BuildConfiguration>

Also the engine source code contains xml schema, you might find it useful to validate data type for xml elements.
You can also use mTail and ProcessMonitor to learn how to setup firewall if your firewall is blocking by default.

I have tiny follow up question.

My situation is quite opposite. I work on Windows and my Friend owns a Mac (also I consider "Mac In Cloud"service if that’s a viable option). I want to use His Mac online for remote builds - which is possible I assume.

My question is - does He needs a UE4 engine and whole project on His behalf (Mac) or only XCode is required and some setup :?