File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -17,20 +17,11 @@ import { createWindow } from "./src/windows/mainWindow.js";
1717
1818const { autoUpdater } = pkg ;
1919
20- // Disable sandbox for Linux
20+ // Disable sandbox on Linux — sandbox restrictions vary across distros
21+ // (AppArmor on Ubuntu, SELinux on Fedora, etc.) and this is an internal
22+ // app where all content is trusted.
2123if ( process . platform === "linux" ) {
22- try {
23- const userns = fs
24- . readFileSync ( "/proc/sys/kernel/unprivileged_userns_clone" , "utf8" )
25- . trim ( ) ;
26- if ( userns === "0" ) {
27- app . commandLine . appendSwitch ( "no-sandbox" ) ;
28- }
29- } catch ( e ) { }
30-
31- if ( process . getuid && process . getuid ( ) === 0 ) {
32- app . commandLine . appendSwitch ( "no-sandbox" ) ;
33- }
24+ app . commandLine . appendSwitch ( "no-sandbox" ) ;
3425}
3526
3627// Setup IPC handlers for renderer process communication
You can’t perform that action at this time.
0 commit comments