[GH-ISSUE #2880] What to do when executable is already in /usr/local/bin? #1802

Closed
opened 2026-05-05 08:28:29 -06:00 by gitea-mirror · 5 comments
Owner

Originally created by @fluks on GitHub (Jul 30, 2019).
Original GitHub issue: https://github.com/netblue30/firejail/issues/2880

I wanted to run riot-web in Firejail, but there is already /usr/local/bin/riot-web, which is a symbolic link to /opt/Riot/riot-web. I installed it from the riot repo. What is the best way to deal with this problem? I also compiled Sylpheed from source and its executable is in /usr/local/bin too.

firejail version 0.9.58.2
Kubuntu 19.04

Originally created by @fluks on GitHub (Jul 30, 2019). Original GitHub issue: https://github.com/netblue30/firejail/issues/2880 I wanted to run riot-web in Firejail, but there is already /usr/local/bin/riot-web, which is a symbolic link to /opt/Riot/riot-web. I installed it from the riot repo. What is the best way to deal with this problem? I also compiled Sylpheed from source and its executable is in /usr/local/bin too. firejail version 0.9.58.2 Kubuntu 19.04
gitea-mirror 2026-05-05 08:28:29 -06:00
Author
Owner

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

There's a whole bunch of possibilities.

  1. change the .desktop file Exec=firejail /opt/Riot/riot-web
  2. symlinking: dir_in_PATH_before_usr_local_bin/riot-web -> /usr/bin/firejail
  3. Replacing /usr/local/bin/riot-web with a shell script #!/usr/bin/env sh\nfirejail /opt/Riot/riot-web "$@"
  4. ...

The best: IDK
The easiest: edit XXX.desktop
My favorit: a shell script in /usr/local/bin

<!-- gh-comment-id:516554910 --> @rusty-snake commented on GitHub (Jul 30, 2019): There's a whole bunch of possibilities. 1. change the .desktop file `Exec=firejail /opt/Riot/riot-web` 2. symlinking: dir_in_PATH_before_usr_local_bin/riot-web -> /usr/bin/firejail 3. Replacing /usr/local/bin/riot-web with a shell script `#!/usr/bin/env sh\nfirejail /opt/Riot/riot-web "$@"` 4. ... The best: IDK The easiest: edit XXX.desktop My favorit: a shell script in /usr/local/bin
Author
Owner

@Vincent43 commented on GitHub (Jul 30, 2019):

Maybe sudo ln -s /usr/bin/firejail /usr/local/sbin/riot-web

<!-- gh-comment-id:516612267 --> @Vincent43 commented on GitHub (Jul 30, 2019): Maybe `sudo ln -s /usr/bin/firejail /usr/local/sbin/riot-web`
Author
Owner

@fluks commented on GitHub (Jul 30, 2019):

Thanks. I choose /usr/local/sbin. It and $HOME/bin are good choices, because I don't have to change them every time riot-web is updated.

<!-- gh-comment-id:516614661 --> @fluks commented on GitHub (Jul 30, 2019): Thanks. I choose /usr/local/sbin. It and $HOME/bin are good choices, because I don't have to change them every time riot-web is updated.
Author
Owner

@rusty-snake commented on GitHub (Jul 31, 2019):

If you copy the .desktop to $HOME/.local/share/applications you need also no changes after an update.

<!-- gh-comment-id:516721822 --> @rusty-snake commented on GitHub (Jul 31, 2019): If you copy the .desktop to $HOME/.local/share/applications you need also no changes after an update.
Author
Owner

@rusty-snake commented on GitHub (Jul 31, 2019):

@fluks I'm closing here due to the question seem answered, please fell free to reopen if you have more questions.

<!-- gh-comment-id:516974470 --> @rusty-snake commented on GitHub (Jul 31, 2019): @fluks I'm closing here due to the question seem answered, please fell free to reopen if you have more questions.
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#1802
No description provided.