23

In Ubuntu 24.04, Thunderbird is installed as a snap app.

How to install thunderbird without snap, e.g. from the Mozilla Team PPA?

2 Answers2

38

You can follow these steps:

  1. First, add the PPA by Mozilla Team.

    sudo add-apt-repository ppa:mozillateam/ppa
    
  2. Then, copy and paste the following code in a terminal in one go (don't copy-paste line by line) to prioritize the apt version of thunderbird over the snap version.

    echo '
    Package: *
    Pin: release o=LP-PPA-mozillateam
    Pin-Priority: 1001
    

    Package: thunderbird Pin: version 2:1snap* Pin-Priority: -1 ' | sudo tee /etc/apt/preferences.d/thunderbird

  3. Next, remove the snap version of thunderbird.

    sudo snap remove thunderbird
    
  4. Install Thunderbird with apt.

    sudo apt install thunderbird
    
  5. To ensure that unattended upgrades do not reinstall the snap version of Thunderbird, enter the following command.

    echo 'Unattended-Upgrade::Allowed-Origins:: "LP-PPA-mozillateam:${distro_codename}";' | sudo tee /etc/apt/apt.conf.d/51unattended-upgrades-thunderbird
    

To undo these changes

  1. Remove the PPA.

    sudo add-apt-repository -r ppa:mozillateam/ppa
    
  2. Remove the apt pin.

    sudo rm -rf /etc/apt/preferences.d/thunderbird
    
  3. Remove the apt version and reinstall the snap one.

    sudo apt remove thunderbird && sudo snap install thunderbird
    

This answer is based on a similar answer for Firefox.

1

Instead of using the mozilla ppa (which is limited to mozilla-owned projects), I chose the Mint distribution. It is also Ubuntu-based, but refuses to use snap. With this, I can not only install thunderbird and firefox (which is also in the mozilla ppa btw), but also chromium if I like, and maybe other packages which do the same snap transition. Maybe, in a far future, I will completely switch to Mint, but until now I'm still happy with Ubuntu (without snap). To avoid overriding my Ubuntu installation with too many Mint packages, I use a strict package pinning (default: Prio 1).

/etc/apt/sources.list.d/mint.list:

# wilma for Ubuntu 24.04
deb http://packages.linuxmint.com wilma upstream
# faye for Ubuntu 22.04
#deb http://packages.linuxmint.com faye upstream

/etc/apt/preferences.d/mint-packages:

# Specify all packages you want to get from Mint instead of Ubuntu
Package: chromium
Pin: origin packages.linuxmint.com
Pin-Priority: 600

Package: firefox Pin: origin packages.linuxmint.com Pin-Priority: 600

Package: thunderbird Pin: origin packages.linuxmint.com Pin-Priority: 600

Do not prefer other packages from the Linux Mint Repository

Package: * Pin: origin packages.linuxmint.com Pin-Priority: 1

Plus, install the keyring. Right know, I don't remember anymore how I did this

Using this, I had to explicitly downgrade thunderbird. Afterwards, it stays stable in the chosen version:

$ sudo apt-get update
$ apt-cache policy thunderbird
$ sudo apt-get install thunderbird="1:128.5.2esr+linuxmint1+xia"

In case, there's something left in snap, try some of the following commands:

sudo snap list
sudo snap remove thunderbird
sudo snap remove firefox
sudo snap remove chromium
Daniel Alder
  • 2,612