Linux Package Installers

This tutorial shows the basics on the apt package installer as well as the nala front end to apt. I discuss snaps, flatpaks and appimages as well.

Snap is an open source “sandboxed” package manager that installs applications from the Ubuntu Snap Store. Although open source, snap is managed and controlled by Canonical giving it a proprietary feel which is the reason that many do not prefer it.

There is a huge variety of snap packages available for both desktops and servers. Snap can provide some valuable solutions. If snap is not installed on your system, install it with the following command:

sudo apt install snap

In the video, I digressed to installing “nala” which is an excellent front end to the Ubuntu/Debian APT package installer.

Install nala by adding the repository and the public key:

echo "deb [arch=amd64,arm64,armhf] scar main" | sudo tee /etc/apt/sources.list.d/volian-archive-scar-unstable.list
wget -qO - | sudo tee /etc/apt/trusted.gpg.d/volian-archive-scar-unstable.gpg > /dev/null

Update your repositories:

sudo apt update

Install nala:

sudo apt install nala  -y

Set the fastest repositories for your updates:

sudo nala fetch

Choose the repositories that you want according the resulting output. In my case:

You can repeat the “sudo nala fetch” to change repositories any time in the future.

You can check for updates:

sudo nala update

You can apply the updates:

sudo nala upgrade

In Ubuntu 22.04 Firefox is installed as a Snap by default. Most people prefer it installed as a regular “apt” package because it is faster.


To uninstall Firefox as a snap:

sudo snap remove firefox

Change the Firefox snap package as a lower priority with the following commands:

echo '
Package: *
Pin: release o=LP-PPA-mozillateam
Pin-Priority: 1001
' | sudo tee /etc/apt/preferences.d/mozilla-firefox

Add the Mozilla repository to your system:

sudo add-apt-repository ppa:mozillateam/ppa

Update to recognize the new repository:

sudo nala update

Install Firefox with nala:

sudo nala install firefox

Now Firefox launched more quickly!

To see if there is a snap package available (for the rocketchat desktop client in this case):

sudo snap find rocketchat

Install the rocketchat desktop client:

sudo snap install rcoketchat-desktop

To list all the snaps installed on your system:

sudo snap list

You can also update an installation of a snap. For example:

snap refresh rocketchat-desktop

Snaps are refreshed according to a schedule. To view the current time:

sudo snap refresh --time

To change the refresh time:

sudo snap set system refresh.timer=fri, 10:00~12:00

To uninstall a snap:

sudo snap remove rocketchat-desktop

To remove the app and its application data (Example: server name, username & password):

sudo snap remove  --purge rocketchat-desktop

To add Flatpak support to Ubuntu:

sudo nala install flatpak

Before you can use flatpak, you must add the flathub repository:

flatpak remote-add --if-not-exists flathub

Now you can search for a package to install:

flatpak search rocketchat

Install the rocketchat client as a flatpak using the Application ID listed:

flatpak install chat.rocket.RocketChat

List the installed flatpaks:

flatpak list

To unistall the rocketchat flatpak:

flatpak uninstall chat.rocket.RocketChat

It should be installed by default, but if you want a GUI for snap installs:

sudo snap install snap-store

Flatpak also has a GUI that can be installed with the following:

sudo apt install gnome-software-plugin-flatpak  gnome-software

To use the flatpak GUI, visit the following address in your browser:

Sometimes an apt installable package is not found in a regular repository that you can add to your system or you might wish not to install the repository. In such cases, you can navigate to where the package is and download it. Be sure you are downloading from a trusted source location.

In the above example, I clicked on the “.deb” file for the rocketchat desktop client and I downloaded it.

The downloaded file will appear in your Downloads folder. I moved over to the downloads folder and the following command installs the file:

sudo dpkg -i  rocketchat-3.9.10-linux-amd64.deb

I am able to uninstall this rocketchat with the following command (yes nala would work too):

sudo apt remove rocketchat

If you can’t find an apt package, a snap or a flatpak, you can install an appimage by simply downloading it. Appimages are self-contained with all of their dependencies and require no installation.

One important requirement is you must make the downloaded app image executable. I can make this change from the CLI by navigating to where the downloaded appimage is and executing the following command (adjust your filename accordingly):

chmod +x  jitsi-meet-x86_64.Appimage

I could also make this change in the GUI through the properties screen on the file by checking the allow executing file as program option:

The beauty of appimages is that the application and all of its dependencies are embedded in a single file that requires no installation process.