tutao / tutanota

Tuta is an email service with a strong focus on security and privacy that lets you encrypt emails, contacts and calendar entries on all your devices.
https://tuta.com
GNU General Public License v3.0
5.86k stars 503 forks source link

Automate Flathub publishing #3493

Open charlag opened 2 years ago

charlag commented 2 years ago

One of our build targets is Flatpak app distributed via Flathub. Our repo is at https://github.com/flathub/com.tutanota.Tutanota/

Flatpak is a sandboxed runtime which is supposed to be built in airgapped reproducible environment. However it is difficult to maintain and the common practice (which we eventually followed) is to pre-build a .tar and just unpack it in the build environment.

Current process of publishing Flatpak app goes like this:

  1. Build normal Tutanota Desktop release
  2. Publish the release on Github
  3. Pull Flathub repo and run ./generate.bash
  4. Push it, upload the resulting tar to the Github release
  5. Open a PR for Flathub repo, see it built (the only thing that failed is tar not being there)
  6. Merge the PR

We would like to minimize manual involvement as much as possible via automation. When we have it we can push directly to the Flathub repo without creating PR.

rihanpharroso commented 2 months ago

@charlag

The "openSUSE Build Service" (OBS) seems to offer automated Flatpak building. I'm not a programmer, but presume it's pretty much the same as the process they offer for automatically building any distro-specific packages. And I believe you can even do both simultaneously, just need to define into what formats (e.g. Flatpak, RPM etc.) and to where (e.g. Flathub) the file shall be exported to.

This manual is about building Flatpaks with OBS: https://openbuildservice.org/2021/02/18/introducing-flatpak-builds/

I hope this helps. :)

Also, here's their GitHub repository: https://github.com/openSUSE/open-build-service

And I'm looking forward to see your Flathub profile verified, of course. Hehe. ;) Thanks for all of your work and for making Tutanota free as in freedom, while also, being affordable!