Safest way to install brave-browser in Distrobox so it's properly isolated? I'm on Fedora Silverblue (Bluefin)

I need to have maximum isolation for my brave browser. So I’m assuming I just create my own home directory:

mkdir -p /home/neo/.brave-home

distrobox create -n brave-fedora -i fedora:latest --nvidia --volume /home/neo/.brave-config:/home/neo/.config/BraveSoftware/Brave-Browser:rw

distrobox enter brave-fedora

sudo dnf install dnf-plugins-core curl

sudo dnf config-manager addrepo --from-repofile=https://brave-browser-rpm-release.s3.brave.com/brave-browser.repo

sudo dnf install brave-browser

mount | grep brave-home

Is this correct or am I doing something wrong? Because when I go to:
ls -la ~/.config/BraveSoftware/Brave-Browser/
It still shows files and it’s not isolated.

Is this command correct?
distrobox create -n brave-fedora -i fedora:latest --nvidia --volume /home/neo/.brave-home:/home/neo/.config/BraveSoftware/Brave-Browser:rw

Thanks in advance

1 Like

You’re close, but the issue is likely with how you’re mounting the config path.

When you do:

--volume /home/neo/.brave-config:/home/neo/.config/BraveSoftware/Brave-Browser:rw

…it assumes the container is using /home/neo as the home dir, but Distrobox usually maps your actual $HOME into the container. So inside the container, ~/.config/BraveSoftware/Brave-Browser is still your real host path. The bind just overlaps or doesn’t isolate like you think.

If you’re aiming for full isolation, best way is to make a fake home:

mkdir -p /home/neo/.brave-home/.config/BraveSoftware/Brave-Browser

Then spin up the box like this:

distrobox create -n brave-fedora -i fedora:latest --nvidia \
  --home /home/neo/.brave-home \
  --volume /home/neo/.brave-home/.config/BraveSoftware/Brave-Browser:/home/neo/.config/BraveSoftware/Brave-Browser:rw

That gives Brave its own config space and keeps it away from your main ~/.config.

Once inside try:

sudo dnf install dnf-plugins-core curl
sudo dnf config-manager --add-repo https://brave-browser-rpm-release.s3.brave.com/brave-browser.repo
sudo rpm --import https://brave-browser-rpm-release.s3.brave.com/brave-core.asc
sudo dnf install brave-browser

Should be good after that. You’ll know it worked if ~/.config/BraveSoftware/Brave-Browser is empty on the host unless you’re inside that .brave-home.

2 Likes

Hi Neo B,
Welcome to the forums.
You can mark the above answer as ‘solution’ if it solved your problem.

Have fun!