4 ms·
Firejail is cool: https://github.com/netblue30/firejail https://github.com/netblue30/firejail Linux namespaces/cgroups but lighter than Docker. I use it when
by sevagh 3y ago
Firejail is cool: https://github.com/netblue30/firejail https://github.com/netblue30/firejail
Linux namespaces/cgroups but lighter than Docker.
I use it when I want to limit the memory of a Python script:
```
maxmem="56" #GB
firejail --noprofile --rlimit-as=${maxmem}000000000 python myscript.py
```
- aredirect 3y agohave to say: i really like the idea of `firejail firefox` thanks for sharing that!
- xigoi 3y agoHow is it better for this use case than just using rlimit?
- dharmab 3y agoI'm not sure about this specific use case, but a reason for using cgroupv2 over rlimit is that cgroup allows you to limit the resources of a _group_ of processes, which is handy if, say, your Python script uses the `subprocess` module.