trampgeek / jobe

jobe is a server that runs small programming jobs in a variety of programming languages
MIT License
111 stars 80 forks source link

Adding password protection to Jobe server prevents connection with Moodle #79

Closed dragos5436 closed 2 months ago

dragos5436 commented 3 months ago

Hi there,

We've recently set up a Jobe server for our institution following your instructions from the jobeinabox repo. The server works, it is able to receive and execute requests from Moodle. However, after adding password protection to the Jobe server so that it's not open to the public, we get a "Sandbox submission limit reached" error when trying to execute code within the coderunner plugin: image

The way we set this up was by first creating a .htpasswd password file on the server and then adding this block of code to the <VirtualHost *:443> of the 000-jobe.conf file:

" AuthName "Dialog prompt" AuthType Basic AuthUserFile /var/www/html/.htpasswd Require valid-user " Is there any setting in Moodle where we could allow outgoing requests to bypass the authentication?

Thank you.

trampgeek commented 3 months ago

The usual way to control access to a Jobe server is via the firewall: see https://github.com/trampgeek/jobe?tab=readme-ov-file#securing-the-site. I recommend that approach, unless there's some reason it won't work for you?

dragos5436 commented 2 months ago

Hi,

Thanks for the tip, we'll try to use the recommended approach. Will re-open this if we run into any other issues.