How to Build and Deploy Your Own Wire Client for Android with flow.ci

Last month, the secure messaging service Wire has gone open source and encouraged users to build compatible clients. In a CI sense, we have already joined in. We forked the Wire Android client (used the original code), built it on flow.ci, deployed it to fir.im beta app distribution platform.

What is Wire?

Wire is one of the growing number of messaging services that have a privacy-first approach to development and business. Claimed to be one the most secure services out there, Wire offers always-on end-to-end encryption supporting private communication in the form of text messaging, voice and video calls as well as file transfers. Wire promises to be different from most messaging services, by not monetizing on user data, not profiling users and no showing ads. They have entered the market almost two years ago and estimated to have 1–2 million MAU. In July, the Wire team has open-sourced the web and native clients (iOS, Android, ..), components related UI layer as well as other tools that they use internally. Wire’s CTO said one of the reason to go open source is to improve transparency of the product.

Lets get started!

In this guideline, we assume that you have a Github account and it is already connected to flow.ci. If by any chance it is not the case please visit flow.ci documentation to learn how to connect your Github account to flow.ci. (Hint: it’s easy.)

  1. Go to Wire’s Github account and fork the wire-android repo, by clicking on the “Fork” button.

2. Sign in to flow.ci to set up a flow for your forked Wire-Android project.

Note: If you have already read our Continuous Deployment for Android , How to Set up Android Emulator in flow.ci, guidelines or you just simply know how to do it, please jump ahead to step 9.

3. Click create project.

4. Choose Github.

5. Choose the account you used to fork the wire-android repository.

6. Select wire-android repository.

7. Click to create your (first) flow.

8. Select the Android default template. This will add the steps of the corresponding default workflow automatically.

9. Select jdk8 and finish creating the project by clicking create.

10. Your project is created. :) It sounds good, but the finish line is still far away.

If you click into the Build plugin you will see that it does not contain the right execution command for the Wire Android repository. Therefore you need to make a simple customization.

11. Add a Custom Script plugin by clicking on the “+” sign after the Build step and selecting it from the plugin list.

The newly added Custom Script plugin is empty. (If you don’t make any changes to it, it won’t affect your flow.)

12. After adding the Custom Script plugin, go back to the original Build plugin and copy the content of the black box. Paste this into the black box in the Custom Script plugin then delete the last line of the script:

  • flow_cmd “./$BASE_NAME — info build” — echo — assert

13. Once you are done, paste the following line twice to the end of the if statement (hint: green box) :

  • ./$BASE_NAME — info assembleDev

Optionally, you can rename the plugin by clicking on the title line and modifying the text there. It might sound obvious, but name the step (plugin) in a descriptive way, so in the future, you can remember what this step does without clicking into it. When you are done click save.

14. Remove the default Build plugin from the flow. To do this, go back to the default Build step and click on the red dustbin button.

15. To be able deploy fir.im beta app distribution platform, add the fir.im Uploader plugin to your flow. Adding the fir.im Uploader plugin works the same way as adding the Custom Script plugin (step 11) or any other plugin. Just click on the “+” sign following the build plugin then select the fir.im Uploader plugin from the searchable plugin list. Make sure that the fir.im Uploader plugin comes after the Build plugin.

16. You can configure the fir.im Uploader plugin just by pasting your fir.im API token to the $FIR_API_TOKEN field shown inside the green box in the next picture. Optionally, you can also update the change log and modify the app path. Once you are done, click save.

17. Go to Jobs (it is in the top menu) and trigger a build either manually or with a git push. Ideally, you should see something like this.

18. If your flow passed (all green), open the log of the fir.im Uploader plugin by clicking on View log under the fir.im Uploader step. Scroll down to the bottom of the log text to find the link where your Wire Android app is published.

19. Visit the link that you have found in the log file and scan the QR code to download.

Congratulations! Your have built and deployed your very own Wire Client!

Happy Building!
flow.ci team


flow.ci is a hosted continuous integration and delivery service, designed for teams who need a flexible and scalable solution but prefer not to maintain their own infrastructure. In flow.ci, development pipelines or automation workflows are simply called flows. In a flow, every step is a plugin that can be added by two clicks. You can add as many steps to your flow as you need, and there is no time limit on builds.