diff options
Diffstat (limited to 'snekbox.cfg')
| -rw-r--r-- | snekbox.cfg | 97 | 
1 files changed, 97 insertions, 0 deletions
diff --git a/snekbox.cfg b/snekbox.cfg new file mode 100644 index 0000000..968271c --- /dev/null +++ b/snekbox.cfg @@ -0,0 +1,97 @@ +name: "snekbox" +description: "Execute Python" + +mode: ONCE +hostname: "snekbox" +cwd: "/snekbox" + +time_limit: 5 + +keep_env: false +envar: "LANG=en_US.UTF-8" +envar: "OMP_NUM_THREADS=1" +envar: "OPENBLAS_NUM_THREADS=1" +envar: "MKL_NUM_THREADS=1" +envar: "VECLIB_MAXIMUM_THREADS=1" +envar: "NUMEXPR_NUM_THREADS=1" + +keep_caps: false + +rlimit_as: 700 + +clone_newnet: true +clone_newuser: true +clone_newns: true +clone_newpid: true +clone_newipc: true +clone_newuts: true +clone_newcgroup: true + +uidmap { +    inside_id: "65534" +    outside_id: "65534" +} + +gidmap { +    inside_id: "65534" +    outside_id: "65534" +} + +mount_proc: false + +mount { +    src: "/etc/ld.so.cache" +    dst: "/etc/ld.so.cache" +    is_bind: true +    rw: false +} + +mount { +    src: "/lib" +    dst: "/lib" +    is_bind: true +    rw: false +} + +mount { +    src: "/lib64" +    dst: "/lib64" +    is_bind: true +    rw: false +} + +mount { +    src: "/snekbox" +    dst: "/snekbox" +    is_bind: true +    rw: false +} + +mount { +    src: "/usr/lib" +    dst: "/usr/lib" +    is_bind: true +    rw: false +} + +mount { +    src: "/usr/local/lib" +    dst: "/usr/local/lib" +    is_bind: true +    rw: false +} + +cgroup_mem_max: 52428800 +cgroup_mem_mount: "/sys/fs/cgroup/memory" +cgroup_mem_parent: "NSJAIL" + +cgroup_pids_max: 1 +cgroup_pids_mount: "/sys/fs/cgroup/pids" +cgroup_pids_parent: "NSJAIL" + +iface_no_lo: true + +exec_bin { +    path: "/snekbox/.venv/bin/python3" +    arg: "-Iqu" +}  |