Open jakubgs opened 4 years ago
This is a considerable amount of work, and should probably wait till https://github.com/status-im/status-react/pull/10936 is done.
is it still relevant @jakubgs ?
It would be nice to have, yes. Currently we build just by running commands in nix-shell
, but a more structured build would be more reproducible.
@jakubgs still relevant?
Yes.
Description
Currently the way iOS is built is by calling Fastlane in a Nix shell. To make it match Android it should be built by a derivation.
Details
Currently when you call
make release-ios
we start a Nix shell forTARGET=ios
: https://github.com/status-im/status-react/blob/fe5b5ab4bc1cf4baf554406b2885c61424becdaf/Makefile#L168-L173 Which is different form how we build it via CI:https://github.com/status-im/status-react-jenkins/blob/1aef5c941161647bbb62986405f52edd1140b7b1/vars/ios.groovy#L44-L52
But Android build essentially just calls
nix-build
with a bunch of arguments related to signing: https://github.com/status-im/status-react/blob/fe5b5ab4bc1cf4baf554406b2885c61424becdaf/scripts/release-android.sh#L81The derivation will have to combine elements of
nix/mobile/ios/pod-shell.nix
andnix/mobile/ios/default.nix
. It might also require a wrapper script likescripts/release-android.sh
to provide the env variables likeFASTLANE_PASSWORD
orFASTLANE_APPLE_ID
.Possible Issues
The build cannot be run using Nix sandbox because Fastlane Match requires network connection to fetch the certificates and keys from our
ios-certificates
repo.Acceptance Criteria
Being able to build iOS app with:
And
make release-ios
does the same thing vianix/scripts/build.sh
.