[GH-ISSUE #2728] Installing some Linux packages in overlayFS? #1718

Closed
opened 2026-05-05 08:23:00 -06:00 by gitea-mirror · 3 comments
Owner

Originally created by @garywill on GitHub (May 29, 2019).
Original GitHub issue: https://github.com/netblue30/firejail/issues/2728

Hello firejail,

I want to try some software on my Linux but don't want to install them to my real system. Installing to firejail overlay FS is an option.

But I can't use sudo to install in firejail. Running firejail as root is not a good idea, and root in firejail can't use X.
What I want to do to overlayFS is

  1. Installing software as root
  2. Running software (GUI) as general user

Is there some way to do that? Does (will) firejail support uid/gid shifting (including FS)?

Originally created by @garywill on GitHub (May 29, 2019). Original GitHub issue: https://github.com/netblue30/firejail/issues/2728 Hello firejail, I want to try some software on my Linux but don't want to install them to my real system. Installing to firejail overlay FS is an option. But I can't use sudo to install in firejail. Running firejail as root is not a good idea, and root in firejail can't use X. What I want to do to overlayFS is 1. Installing software as root 1. Running software (GUI) as general user Is there some way to do that? Does (will) firejail support uid/gid shifting (including FS)?
gitea-mirror 2026-05-05 08:23:00 -06:00
Author
Owner

@rusty-snake commented on GitHub (May 29, 2019):

@garywill what about https://firejail.wordpress.com/documentation-2/basic-usage/#overlayfs?

<!-- gh-comment-id:496912500 --> @rusty-snake commented on GitHub (May 29, 2019): @garywill what about https://firejail.wordpress.com/documentation-2/basic-usage/#overlayfs?
Author
Owner

@rusty-snake commented on GitHub (May 30, 2019):

https://github.com/netblue30/firejail/issues/1139#issuecomment-306063071

This is an example using OpenShot video editor:

In a terminal start a overlayfs sandbox (you would need a kernel 3.18 or better):

$ firejail --name=test --overlay --private --noblacklist=/sbin --noblacklist=/usr/sbin

In a different terminal, join the sandbox as root and install the program - I am using apt-get on Debian:

$ sudo firejail --join=test
Switching to pid 2464, the first child process inside the sandbox changing root to /proc/2464/root
Child process initialized in 6.05 ms
# apt-get install openshot
# exit

Back in the first terminal run the program

$ openshot

Once you close both sandboxes, overlayfs is disabled and openshot disappears.

<!-- gh-comment-id:497450168 --> @rusty-snake commented on GitHub (May 30, 2019): https://github.com/netblue30/firejail/issues/1139#issuecomment-306063071 > This is an example using OpenShot video editor: > > In a terminal start a overlayfs sandbox (you would need a kernel 3.18 or better): > > $ firejail --name=test --overlay --private --noblacklist=/sbin --noblacklist=/usr/sbin > > In a different terminal, join the sandbox as root and install the program - I am using apt-get on Debian: > > $ sudo firejail --join=test > Switching to pid 2464, the first child process inside the sandbox changing root to /proc/2464/root > Child process initialized in 6.05 ms > # apt-get install openshot > # exit > > Back in the first terminal run the program > > $ openshot > > Once you close both sandboxes, overlayfs is disabled and openshot disappears.
Author
Owner

@rusty-snake commented on GitHub (May 30, 2019):

I think this is answered, @garywill if not or you have future questions, feel free to reopen.

<!-- gh-comment-id:497453654 --> @rusty-snake commented on GitHub (May 30, 2019): I think this is answered, @garywill if not or you have future questions, feel free to reopen.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/firejail#1718
No description provided.