Sudo apt install -install-recommends winehq-stable sudo apt-add-repository 'deb bionic main' For me it was bionic (you can get yours using command lsb_release -cs), but check official instructions if that does not correspond to yours. If you encounter an error, then try to run the following command before installing winehq-stable again: sudo apt install libasound2-plugins:i386 Note that I could not install winehq-stable directly and had to first install one of its dependencies manually. Installing Firejailįirejail has a special place in my heart. It allows to sandbox any program running on Linux using kernel capabilities (some of them you might already know from Docker world).
From the official repository:įirejail is a SUID sandbox program that reduces the risk of security breaches by restricting the running environment of untrusted applications using Linux namespaces, seccomp-bpf and Linux capabilities. It allows a process and all its descendants to have their own private view of the globally shared kernel resources, such as the network stack, process table, mount table. Firejail can work in a SELinux or AppArmor environment, and it is integrated with Linux Control Groups. You can specify a different directory to be used as the ~/ (home) folder of each program you run in a sandbox instead of your real home. This is great because it allows to keep files and folders of each app nicely isolated. For example I run thunderbird, cliqz and other programs in sandboxes and assign them different homes like ~/.sandboxes/thunderbird, ~/.sandboxed/cliqz, etc. This means that I can clean-up all files for each program by simply deleting their respective folders! That’s super convenient. Let’s get back to Diablo II! Install Firejail from your official Linux repositories (or compile it yourself if that’s your thing… that’s what I did). That’s the one we will be using! Preparing Wine Home Folder I am currently running version 0.9.61 but I assume this should work with other versions as well.įirejail comes with a preset for sandboxing wine which you can find at /etc/firejail/wine.profile.