Bitrise Workflow Self Setup

Reseller accounts must setup their own device builds. This requires setting up workflows in Bitrise, you can read what workflows are here.

AppPresser has custom workflows that are setup on your account. You can choose to use AppPresser workflows, or setup your own.

Android debug building requires no setup. To build for an iOS device, or the app stores, you must upload your certificates, and then define environment variables.

Video

https://www.loom.com/share/e0a51260475c42be99fd616cd3314aec

Workflows

First, login to Bitrise, find your app in the right sidebar, and click the app name. Next click Workflows. Here you will see all of your workflows, you can click any of them to see how they work.

Click Code Signing, this is where you will upload your certificates and profiles.

Provisioning Profiles

Under Code Signing, scroll down and click to add a provisioning profile. Upload your profile, and copy the ID. You will use this in your environment variables later.

iOS Certificates

Scroll down CODE SIGNING CERTIFICATES, and add your development and production .p12 files. After adding your certificate, click the eyeball icon, and enter your password, then save.

Environment Variables

Click on "Env Vars" in your workflow editor.

Add the variables described below by clicking Add New in the App Environment Variables section, and entering the name exactly as shown, in all caps.

Variable Reference

Replace variables in inputs set to true

Required for iOS development:

$APP_DEVELOPMENT_PROFILE = the ID of the development provisioning profile. Get this when you upload it, for example c302c49e-7528-469b-b49d-12f187387e47

$APP_DEVELOPMENT_TEAM = when you upload the cert, it is the characters in parentheses. For example Team: WP4, LLC (TNZ27UV2JH) would be TNZ27UV2JH. See the highlighted portion in the image below.

Required for ad hoc:

$APP_ADHOC_PROFILE = (optional if you are testing push) the ID of the ad hoc provisioning profile. Get this when you upload it, for example c301c49e-7228-469b-b49d-12f187387e47

Required for iOS app store submission:

$APP_RELEASE_PROFILE = the ID of the app store provisioning profile. Get this when you upload it, for example c301c49e-7528-469b-b49d-12f287387e47

$APP_STORE_TEAM_ID = not the same as development team. Go to apple dev center, click account, then membership. Under Membership Information, you can get the Team Name and Team ID fields.

$APP_BUNDLE_ID = (do not add this twice) Go to settings > App ID in the customizer, looks like com.presschat.app.

All iOS secret variables are also required, see below.

Required for Google Play submission:

All Android secret variables are required for submission.

$APP_BUNDLE_ID = (do not add this twice) Go to settings > App ID in the customizer, looks like com.presschat.app.

Keystore file

Upload under generic storage, use the name "KEYSTORE".

$BITRISEIO_KEYSTORE_URL = url to the keystore file in generic storage

Secret variables

The secret variables below are required for app store submission.

You can define these in app => workflow => Secrets.

iOS Secrets

$APP_STORE_USERNAME = app store connect username

$APP_STORE_PW = app store connect pass

$APP_SPECIFIC_PW = application specific password used to bypass 2 factor auth. See this article. Important - when using an account that doesn't have 2 factor auth setup need this variable cleared, otherwise app store submission will fail. Visit workflows => app-store-ios workflow => Click Deploy to iTunes Connect, scroll to Application Specific Password and press Clear. Save.

Android Secrets

$KEYSTORE_ALIAS = the alias

$KEYSTORE_PW = password used for the keystore. There are 2 passwords for the keystore, they both use this same input. If for some reason someone has different passwords, you will have to change that manually in the workflow editor.

$ANDROID_JSON_KEY_PATH = you must create this file, see this. Upload the key file to Workflows => Code Signing => Generic Storage. You must go to the play store workflow, click Deploy to Google play at the bottom left, and then click the "Service Account JSON key file path" field, and add the variable you just created.

Once the correct certs have been uploaded and these variables have been defined, everything should work automatically.