Skip to content

Commit

Permalink
fs restriction
Browse files Browse the repository at this point in the history
  • Loading branch information
vr-varad committed Feb 13, 2025
1 parent 47db267 commit 4ea6178
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion worker/utils/codeRunner.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ const codeRunner = async (language, code) => {
throw new Error('Unsupported language');
}

const containerCommand = `docker run --rm -u ${userId} --cpus=1 --pids-limit=100 ${imageName} sh -c 'timeout 10s ${command}'`;
const containerCommand = `docker run --rm -u ${userId} --read-only --tmpfs /tmp --cpus=1 --pids-limit=100 ${imageName} sh -c 'timeout 10s ${command}'`;


try {
Expand Down

0 comments on commit 4ea6178

Please sign in to comment.