How to submit an iOS .ipa app without Xcode and a Mac?

Stephane Delecroix
2 min readNov 29, 2020

I am using expo sdk and Linux to develop mobile app. I don’t have a mac, but I published on PlayStore and on Apple Store. You may adapt the following code to your needs but the following should be working for any kind of project .

I give you my solution designed by my workmate to publish on App Store without a mac, using travis-ci. This article is about sending the .ipa to App Store.

You will still have to pay an Apple Dev Account. I let you find a tutorial if you don’t know how.

First you will need to create an Ios build:

expo build:ios

Choose the setting you need.

Save url of your .ipa for later. It should look like:

https://exp-shell-app-assets.s3.us-west-1.amazonaws.com/ios/%40username/e2071344b80273HN84aad86-bf40fr86-1006–2dad-0902-61dc297b7d41-archive.ipa

We will use travis-ci. In your app folder, create a .travis.yml file. Create an account on travis and give it access to your github repo. (Yes I am assuming your are using github).

Then copy paste:

language: node_js
cache:
bundler: true
npm: true
node_js:
- 10.16.0
jobs:
include:
- stage: deploy
if: type = api
test: skip
install: skip
script: ./deploy.sh
os: osx
osx_image: xcode11.2

In a nutshell, we are asking travis to use an osx vm.

Then create deploy.sh

#!/usr/bin/env bash

if [[
$OS = "ios" ]]
then
echo "Deploy on testflight"
echo $URL
wget $URL;

IFS='/' read -ra ELEMENT <<< "$URL"

FILENAME=${ELEMENT[${#ELEMENT[@]}-1]}
mv "$FILENAME" "$FILENAME"
echo 'filename'
echo $FILENAME
sudo xcode-select -r
xcrun altool --upload-app --type ios --file $FILENAME --username yourEmail@email.com --password your-generated-password

echo 'upload finished'
fi

You can hard code it in your repo at your own risk, or you can encrypt it with travis ci.

‘your-generated-password’ has to be generated for your app: https://support.apple.com/en-us/HT204397. It is not your real password you use to login.

Then use curl or postman to send this http request travis api to trigger travis build:

Don’t forget to add in authorization header your travis api token.

Authorization: token se1OTIACCaZdvX423bd3uB

{
"request": {
"message": "[BUDDY] iOS deploy request",
"branch":"develop",
"config": {
"merge_mode": "deep_merge_append",
"before_script":"export OS=ios URL='https://exp-shell-app-assets.s3.us-west-1.amazonaws.com/ios/%40username/e2071344b80273HN84aad86-bf40fr86-1006–2dad-0902-61dc297b7d41-archive.ipa'"
}
}
}

Then you should see something like this! And in few minutes, you will see your app in you Apple Account!

Let me know if you have question or trouble.

--

--