You can install a full version of Debian Stable on the Linux development environment on most Chromebooks. If you want access to newer apps, many popular Linux apps are available as Flatpak packages. It can be difficult to get apps like this working on a Chromebook, but the process is easy once you know how.
Why Flatpak?
As convenient as it is to use a Chromebook, there always seems to be some apps you want to use that aren’t available as a web app, or work differently as a web or Android app than as a desktop app. You might even want to install browsers other than Chrome, e.g. e.g.Firefox.
The version of Debian installed by default in the Crostini environment is the stable version, which is rather conservative in terms of software. The stable version of Debian prefers older software versions.
It’s also difficult for upstream developers to maintain open-source apps when Linux distribution maintainers change a program for their users. If the user reports an error, who is responsible for fixing it?
Flatpak is an attempt to standardize packages for Linux. The idea is that the developers only have to ship one app with all its dependencies. The app is isolated from the libraries on the system, which makes troubleshooting easier.
The main reason to install Flatpak is that you will have newer versions of apps than with APT.
Install Flatpak on Chromebook
It’s easy to install Flatpak on Linux on a Chromebook. You need to enable nested containers or you might encounter errors when trying to install packages.
To do this, enter a Crosh session by pressing Ctrl-Alt-T
Then enter these commands to enable nested containers:
vmc start termina
lxc config set penguin security.nesting true
exit
vmc stop termina
Now you want to install Flatpak with APT in Linux environment. Open a terminal and enter the following:
sudo apt install flatpak
Now that Flatpak is installed, it’s time to find some packages.
find packages
There are two ways to search for packages to use with Flatpak. You can search from the command line, similar to “apt search”:
flatpak search app
For example, if you’re looking for Firefox, type:
flatpak search firefox
You can also browse the Flathub website graphically. This is a good idea if you don’t know exactly what you want.
Clicking Install will download the package reference. The pages also contain command line instructions.
Installing Flatpak packages
Installing Flatpak packages is similar to installing APT packages.
To install a specific package, you need to find the package ID, either by searching on the command line or via Flathub.
For example to install Firefox
sudo flatpak install org.mozilla.firefox
You can also download the package reference from Flathub. If you do this, you should make your Downloads folder available to Linux.
To install downloaded packages, navigate to the shared directory. For example:
cd /mnt/chromeos/MyFiles/Downloads
Then enter this command
sudo flatpak install name.of.package.file
It’s easier to follow the command line instructions.
For example to install Firefox with Flathub
sudo flatpak install flathub org.mozilla.firefox
Once your new packages are installed, you can access them like any other Linux app on the system. You can find them in your apps by using the search menu or by calling them from the command line.
Using the command line is slightly different with Flatpak. A Flatpak app is usually not found. You must use the Flatpak command line app to invoke it.
To start Firefox from the shell, type:
flatpak run org.mozilla.firefox
Since this is a lot to type, it’s a good idea to set a shell alias for any Flatpak apps you use frequently on the command line:
alias firefox='flatpak run org.mozilla.firefox'
Now you can install Flatpak apps on your Chromebook
Keeping your favorite apps up to date is easy with Flatpak on your Chromebook. The Chromebook Linux environment lets you get even more out of your Chromebook by allowing you to install full-fledged apps, not just Android and web apps. Only a few clicks are required for installation.