One of our project is a react native app for both Android and iOS, and we’d like to have a single CI jobs testing the validity of pull requests.
Do you plan to provide a combined iOS+Android stack in the near future?
Android SDK on OSX?
iOS & Android build in same repo for Cordova
Create React Native box
iOS and Android stacks together
How to build Ionic 2 apps
Thanks for the feature request!
For some extent this is already possible on the Xamarin stacks, as those include both Xcode and Android SDK, but the updates are tied to Xamarin updates.
We do have plans for a separate “cross platform” stack, where update schedules are not tied to Xamarin, but we don’t have an ETA yet.
Alternative, already available solution
Btw the workaround / alternative (which has its own PROs and CONs of course) right now is to register the same repository two times, once as an iOS app (using a Mac/Xcode stack) and once as an Android one (using the Android/Linux stack).
This approach has the advantage that if you have 2 concurrencies then it will most likely finish faster than a single build which would include building both, as well as that the Linux environment is way more customizable and easier to debug due to
docker support - see for example this DevCenter guide about how you can download the Linux environment and run your build in it locally, using
From @Almouro on Mon Jul 11 2016 06:19:59 GMT-0400 (EDT)
At @bamlab, we use Bitrise for our React Native projects, and we like to build both Android and iOS versions of the project on the same stack.
For now, we made a custom step installing Android SDK with Brew via a script, and adding the required tools.
Do you think it would be a good idea to include the Android SDK on the OSX stacks? If so, should we make a PR on https://github.com/bitrise-io/osx-box-bootstrap?
Or do you think it’d be best to submit an Android SDK step for the OS stacks?
Copied from original issue: https://github.com/bitrise-io/bitrise.io/issues/45
From @viktorbenei on Mon Jul 11 2016 06:59:52 GMT-0400 (EDT)
Note: the Xamarin stacks have both Android and Xcode preinstalled, but the update schedule of the stacks is tied to the Xamarin tool updates
We definitely have plans for cross platform stacks, but there are a couple of things we have to consider:
- How should we schedule updates for the stack? Should it be updated to the latest Xcode version automatically? To the latest React Native / Cordova / node / etc.?
- It’s not possible to run macOS inside a Docker container. Docker can run on a macOS host, but the guest can only be Linux. The issue is, there’s no real alternative for macOS right now, to provide images for the environment. We try to move in the direction that you can download & use the same environment you have on Bitrise, for easier configuration & debugging. That’s possible with Docker and with a Linux guest (when your build “runs on Linux”), and we plan to support this use case (to let you work with the same environment on your Mac/PC) even more in the future, as that makes development and testing way easier. Unfortunately we don’t know about any possible solution for macOS, and because of licensing issues we can’t even provide the virtual machine images we use on bitrise.io. This means that all we can provide are the scripts we use to prepare the clean macOS (https://github.com/bitrise-io/osx-box-bootstrap), but you have to create the virtual machine yourself and then run the scripts on it. This is quite a complicated process, usually too complicated to be a viable debug option.
There are other pros & cons, like if you have your app configured as two projects/apps on Bitrise (one for macOS/iOS and one for Linux/Android), then you can run the two builds in parallel (given that you have at least 2 concurrency on bitrise.io), as well as other, usually less significant points like to be able to have control over the tool versions separately for your two configuration (e.g. a newer Node version for one config, an older one for the other one).
So, right now we can’t promise anything. We definitely aware of this use case and we’re thinking about the best solution, but we have to consider quite a lot of things.
Feel free to vote & comment here, we’re eager to hear what you think! Every use case you share can help us refine the requirements, and to get us closer to the “right” solution
Attempting to reply to prior question, “iOS & Android build in same repo for Cordova” but that thread is now locked. What is the general idea to get it working. I actually found the thread “Android SDK on OSX” more understandable although its also locked. As described there, it seems that there are two general possible approaches:
- Have a single environment that supports both Xcode and Android builds.
- Have 2 projects on bitrise, one for Android one for iOS. How would this work. Can you configure two projects from the same github repo? How do you specify separate build configurations?
In the earlier reply, is describing approach 1 or 2?
It was locked because it was moved here - it’s noted at the end of the discussion at Android SDK on OSX? , sorry for the confusion.
So, to answer your question: please see my reply above Xcode + Android SDK combined stack , I think that will answer your questions, but if not, just let us know here!
All Xcode stacks now have Android SDK & tools preinstalled, so closing this feature request.
Thanks everyone for requesting and voting
This topic was automatically closed after 14 days. New replies are no longer allowed.