3. Installation¶
This document describes how to install the VPL Jail System. For more details about VPL, visit the VPL home page or the VPL plugin page at Moodle.
3.1. Selecting the hardware¶
The recommended option is using a dedicated machine. If you cannot use a dedicated computer, try using a virtual machine on a shared host, e.g. using VirtualBox. This approach will provide isolation and limit the resources used by the service. If you decide to install the service on a machine with other uses, beware that resource usage by the VPL Jail System may decrease the performance of the other services. Although no security breach has been reported, the nature of the service (executing external code) carries an intrinsic threat.
3.2. Preparing the system¶
Install a Linux OS as clean as possible. At the very least, install the “en_US.UTF-8” locale along with any other locales you require. Note that the VPL plugin will attempt to use the locale set in Moodle. However, if setting the Moodle locale fails, it will fall back to “en_US.UTF-8”, “C.utf8”, “POSIX”, or “C” (in that order).
Stop any services you don’t need, such as the web server, SSH server, etc. If the operating system has a firewall, you must configure it (or disable it) to allow access to the one or two ports needed by the VPL Jail System. If you use automatic updates, you must restart the VPL Jail System to apply the updates. You can use cron to automate this process.
3.3. Getting the VPL Jail System¶
The VPL Jail System is distributed as source files. You must get the source package from https://vpl.dis.ulpgc.es/, e.g., using
wget https://vpl.dis.ulpgc.es/releases/vpl-jail-system-[version].tar.gz
or download it from the GitHub repository at https://github.com/jcrodriguez-dis/vpl-jail-system/releases.
3.4. Building the package from the source code¶
If you have the source code of the VPL Jail System, you can build the package yourself by running the following commands:
aclocal
autoheader
autoconf
automake
./configure
make distcheck
You must have installed the GNU Autotools (autoconf, automake, etc.) to run these commands and build the package. Also, you need to have the development packages of the libraries such as g++ make autotools-dev autoconf.
3.5. Running the installer¶
After obtaining the package, you must decompress it to run the installer. Example of decompressing the package: .. code:: bash
tar xvf vpl-jail-system-[version].tar.gz cd vpl-jail-system-[version]
The installer has several functionalities:
- It updates the installed software packages in the system.
- Installs the minimum packages needed for compiling the server, if necessary.
- Installs or updates the configuration file with user confirmation.
- Installs or updates launchers and service control scripts.
- Compiles the server
vpl-jail-serverand attempts to install or update it. If the server is running, the installer cannot update it.- Based on the command-line options, the installer installs the selected packages. Additionally, you can install manually other packages you need before starting the service. To automate the process of installing other packages, you can modify files in the package_files directory.
- The installer may ask you about certificates for HTTPS connections.
- The installer may ask you to install other specific software that requires user intervention.
- Following the parameter options, the installer can finally start the service.
Example of running the installer: .. code:: bash
./install-vpl-sh noninteractive minimum start
Note
The “./install-vpl-sh” script must be run as root.
3.5.1. Command Line Options¶
help: Display help information.update: Update the VPL Jail System server software.start: Start the VPL Jail System service post-installation.noninteractive: Enable installation without user interaction.list: Show packages to be installed per [inst_level].[inst_level]: Set installation level (minimum,basic,standard,full).uninstall: Removes all packages in the “full” set except those in the “minimum” set (Added in 5.0.0).
Examples:
./install-vpl-sh update
./install-vpl-sh standard noninteractive start
./install-vpl-sh full
If run without options (interactive mode), follow the instructions and wait for the necessary downloads. The installation script will try to install the development software commonly used.
In interactive mode, the installer may prompt you about certificates and optional software.
Note
If you have your own SSL certificates for the HTTPS and WSS communications, you must copy your public certificate to the “/etc/vpl/cert.pem” file and the private key to the “/etc/vpl/key.pem” file. You also can change the configuration file to tell the system the location of your certificates. If your Certification Authority (CA) is not a root CA you may need to add the intermediate CA certificates to the “cert.pem” file. You may restart the service to apply the modifications.
3.6. Installer command-line options¶
Note
You can install manually all the development software you want to use.
./install-vpl-sh [OPTIONS] [inst_level]
where [OPTIONS] can be:
- help Show this help message and exit.
- update Update the VPL Jail System server software.
- start Start the VPL Jail System service after installation.
- noninteractive Install without user interaction.
- [inst_level]
Install programming languages development packages:
values:
minimum|basic|standard|full - list
Show the packages to install by
[inst_level].
3.7. Examples¶
./install-vpl-sh update
Update the VPL Jail System server software.
./install-vpl-sh standard noninteractive start
Install in non-interactive mode standard packages and start server.
./install-vpl-sh full
Install all known dev packages in interactive mode.
3.8. VPL Jail System images available on Docker Hub¶
You can access built images of the VPL Jail System running on different operating systems. The official account that distributes these images is jcrodriguezvpl. There is a repository for each operating system (e.g. jail-fedora-full).
3.9. Adding the jail/execution server to the VPL plugin at Moodle¶
The URL of the service is https://yourservername:SECURE_PORT/URLPATH or http://yourservername:PORT/URLPATH
:SECURE_PORT and :PORT can be omitted if using the standard port numbers.
You can use the jail server URL in the VPL plugin configuration (requires administration rights) and, in the local execution server settings of a VPL activity.
3.10. Updating VPL Jail System¶
If you want to update the VPL Jail System to a new version, download the new version and run the installer with the update option.
./install-vpl-sh update
3.11. Updating the software in the jail¶
After installing or updating packages or files in the host system, you must restart the service with
systemctl restart vpl-jail-system
to make the changes available in the jail.
Note
From version 5.0.0, the firewall configuration allows package updates and installations without stopping the server. However, the service must be restarted to apply changes.
If you don’t want to restart the service, you can drop the kernel caches to do the overlayFS file system aware of the changes. To drop the kernel caches, run as root:
sync; echo 7 > /proc/sys/vm/dropcaches
3.12. Removing VPL Jail System¶
Run the uninstall.sh script from the current version to remove the vpl-jail-server.
Run ./install-vpl-sh uninstall to remove all packages in the “full” set except
those in the “minimal” set.
3.13. Development tools the installer may install¶
Note
From version 4.0.3, the list of packages to install has been extracted to separate files located in the package_files directory, allowing for better customization.
If you wish, the installer can try to install some development tools for you, and you can also install by hand the development tools you prefer. The automatically installed tools depend on your Linux distribution, package manager, and the names of the packages. The installer supports APT, DNF, APK, and YUM package managers.
3.13.1. Development tools installed using yum/dnf¶
| Package name | Description | Level |
|---|---|---|
| gcc-gnat | Ada compiler (GNU) | standard |
| nasm | Assembler | standard |
| autoconf | Autotools autoconf | minimum |
| automake | Autotools automake | minimum |
| gcc | C compiler | minimum |
dotnet-sdk-10.0
dotnet-sdk-9.0
dotnet-sdk-8.0
dotnet-sdk-7.0
mono-complete
|
C#/F#/VisualBasic on DotNet
|
standard
|
| gcc-c++ | C++ compiler | minimum |
| clisp | Clisp | full |
clojure
clojure1.6
clojure1.4
|
Clojure
|
full
|
| gnucobol | Cobol | full |
| coffee-script | CoffeeScript | full |
| gcc-gdc | D compiler (GNU) | full |
| ddd | DDD graphical front end debugger (GNU) | basic |
| erlang | Erlang | full |
| iptables | Firewall | minimum |
| gcc-gfortran | Fortran compiler (GNU) | standard |
| gdb | General purpose debugger (GNU) | basic |
| golang | Go programming language compiler | full |
| haskell-platform | Haskell | standard |
| haxe | Haxe programming language | full |
java-25-openjdk-devel
java-21-openjdk-devel
java-17-openjdk-devel
java-11-openjdk-devel
java-1.8.0-openjdk-devel
|
Java (OpenJDK)
|
basic
|
| openjfx | JavaFX | basic |
| nodejs | JavaScript (Nodejs) | standard |
| js-jquery | JQuery JavaScript Lib | full |
| js-jquery-ui | JQuery-UI JavaScript Lib | full |
| julia | Julia | full |
| junit | Junit framework | basic |
| redhat-lsb-core | LSB core | minimum |
lua
lua5.1
|
Lua compiler
|
full
|
| make | make | minimum |
| spim | MIPS R2000/R3000 emulator | full |
| octave | Octave (GNU) | standard |
| fpc | Pascal compiler | standard |
perl-Modern-Perl
perl
|
Perl interpreter
|
standard
|
| php-cli | PHP interpreter | basic |
| pl | Prolog | standard |
| thonny | Python Thonny | basic |
| python3 | Python3 | basic |
| python3-flake8 | Python3 flake8 | basic |
| python3-matplotlib | Python3 Matplotlib | basic |
| python3-mypy | Python3 mypy | basic |
| python3-networkx | Python3 NetworkX | basic |
| python3-numpy | Python3 NumPy | basic |
| python3-pandas | Python3 pandas | basic |
| python3-pudb | Python3 pudb | basic |
| python3-pycodestyle | Python3 pycodestyle | basic |
| python3-pydocstyle | Python3 pydocstyle | basic |
| python3-tkinter | Python3 Tkinter | basic |
| R | R statistical computation and graphics system (GNU) | full |
| ruby | Ruby interpreter | standard |
| rust | Rust compiler | standard |
| scala | Scala programming language | standard |
| racket | Scheme interpreter | standard |
| sqlite | SQL interpreter | basic |
| openssl | SSL library | minimum |
| openssl-devel | SSL library | minimum |
| tcl | TCL interpreter | standard |
| valgrind | Valgrind tool | standard |
| iverilog | Verilog compiler | full |
ghdl
freehdl
|
VHDL compiler
|
full
|
| tigervnc-server | VNC server | minimum |
| firefox | Web browser | full |
fluxbox
openbox
metacity
|
Window manager
|
minimum
|
| xset | xset | minimum |
| xterm | xterm | minimum |
3.13.2. Development tools installed using apt-get¶
| Package name | Description | Level |
|---|---|---|
| gnat | Ada compiler (GNU) | standard |
| apt-utils | apt-utils | minimum |
| nasm | Assembler | standard |
| autoconf | Autotools autoconf | minimum |
| automake | Autotools automake | minimum |
| bc | bc | minimum |
| gcc | C compiler (GNU) | basic |
dotnet-sdk-9.0
dotnet-sdk-8.0
dotnet-sdk-7.0
dotnet-sdk-6.0
mono-complete
|
C#/F#/VisualBasic on DotNet
|
standard
|
| g++ | C++ compiler | minimum |
| clisp | Clisp | full |
clojure
clojure1.6
clojure1.4
|
Clojure
|
full
|
gnucobol
open-cobol
|
Cobol
|
full
|
| coffeescript | CoffeeScript | full |
| gconf2 | Configuration DB system | minimum |
| gdc | D compiler (GNU) | full |
| dbus-x11 | dbus-x11 | minimum |
| ddd | DDD graphical front end debugger (GNU) | basic |
| erlang | Erlang | full |
| iptables | Firewall | minimum |
| xfonts-75dpi | Fonts | minimum |
| xfonts-100dpi | Fonts | minimum |
| gfortran | Fortran compiler (GNU) | standard |
| gdb | General purpose debugger (GNU) | basic |
| golang | Go programming language compiler | full |
| groovy | Groovy programming language | full |
hgc
hugs
|
Haskell
|
standard
|
| haxe | Haxe programming language | full |
| checkstyle | Java Checkstyle | basic |
openjdk-25-jdk
openjdk-21-jdk
openjdk-17-jdk
default-jdk
openjdk-11-jdk
openjdk-8-jdk
|
Java jdk
|
basic
|
openjdk-25-jre
openjdk-21-jre
openjdk-17-jre
default-jre
openjdk-11-jre
openjdk-8-jre
|
Java runtime
|
basic
|
| openjfx | JavaFX | basic |
| nodejs | JavaScript (Nodejs) | standard |
| nodejs-legacy | JavaScript (Nodejs-legacy) | standard |
| libjs-jquery | JQuery JavaScript Lib | full |
| libjs-jquery-ui | JQuery-UI JavaScript Lib | full |
| julia | Julia | full |
junit4
junit
|
Junit framework
|
basic
|
| libtool-bin | libtool required for VHDL | full |
lsb
lsb-core
lsb-compat
|
LSB
|
minimum
|
lua
lua5.4
lua5.3
lua5.2
lua5.1
|
Lua compiler
|
full
|
| make | make | minimum |
| minizinc | MiniZinc constraint modeling language | full |
| spim | MIPS R2000/R3000 emulator | full |
| net-tools | net-tools | minimum |
| octave | Octave (GNU) | standard |
| fp-compiler | Pascal compiler | standard |
| perl | Perl interpreter | standard |
| php-cli | PHP interpreter | basic |
| php-readline | PHP readline | basic |
| swi-prolog | Prolog | standard |
| thonny | Pythom Thonny | basic |
| mypy | Python mypy | basic |
| pycodestyle | Python pycodestyle | basic |
| pydocstyle | Python pydocstyle | basic |
| python3 | Python3 | basic |
| python3-matplotlib | Python3 Matplotlib | basic |
| python3-networkx | Python3 NetworkX | basic |
| python3-numpy | Python3 NumPy | basic |
| python3-pandas | Python3 pandas | basic |
| python3-pudb | Python3 pudb | basic |
| python3-pycodestyle | Python3 pycodestyle | basic |
| python3-tk | Python3 Tk | basic |
| r-base | R statistical computation and graphics system (GNU) | full |
| ruby | Ruby interpreter | standard |
| rustc | Rust compiler | standard |
| scala | Scala programming language | standard |
plt-scheme
racket
|
Scheme interpreter
|
standard
|
| sqlite3 | SQL interpreter | basic |
| php-sqlite3 | Sqlite for PHP | basic |
| openssl | SSL library | minimum |
| libssl-dev | SSL library | minimum |
| tcl | TCL interpreter | standard |
| valgrind | Valgrind tool | standard |
| iverilog | Verilog compiler | full |
ghdl
freehdl
|
VHDL compiler
|
full
|
| tightvncserver | VNC server | minimum |
firefox
firefox-esr
|
Web browser
|
full
|
fluxbox
metacity
openbox
|
Window manager
|
minimum
|
| xorg | X system | minimum |
| galax | XQuery interpreter | full |
| xterm | xterm | minimum |
3.13.3. Development tools installed using apk¶
| Package name | Description | Level |
|---|---|---|
| gcc-gnat | Ada compiler (GNU) | standard |
| nasm | Assembler | standard |
| autoconf | Autotools autoconf | minimum |
| automake | Autotools automake | minimum |
| bc | bc | minimum |
| gcc | C compiler | minimum |
dotnet9-sdk
dotnet8-sdk
dotnet7-sdk
dotnet6-sdk
mono-dev
|
C#/F#/VisualBasic on DotNet or C# mono
|
standard
|
| g++ | C++ compiler | minimum |
| clisp | Clisp | full |
clojure
clojure1.6
clojure1.4
|
Clojure
|
full
|
| gcc-gdc | D compiler (GNU) | full |
| dbus-x11 | dbus-x11 | minimum |
| erlang | Erlang | full |
| iptables | Firewall | minimum |
| gfortran | Fortran compiler (GNU) | standard |
| gdb | General purpose debugger (GNU) | basic |
| go | Go programming language compiler | full |
openjdk25
openjdk21
openjdk17
openjdk11
openjdk8
|
Java
|
basic
|
| openjfx | JavaFX | basic |
| nodejs | JavaScript (Nodejs) | standard |
junit4
junit
|
Junit framework
|
basic
|
| lsb-release-minimal | LSB | minimum |
lua
lua5.4
lua5.3
lua5.2
lua5.1
|
Lua compiler
|
full
|
| make | make | minimum |
| net-tools | net-tools | minimum |
| octave | Octave (GNU) | standard |
| fpc | Pascal compiler | standard |
| perl | Perl interpreter | standard |
php83
php82
php81
php8
|
PHP interpreter
|
basic
|
| swi-prolog | Prolog | standard |
| thonny | Pythom Thonny | basic |
| py3-xdg | Python XDG | minimum |
| python3 | Python3 | basic |
| py3-matplotlib | Python3 Matplotlib | basic |
| py3-mypy | Python3 mypy | basic |
| py3-networkx | Python3 NetworkX | basic |
| py3-numpy | Python3 NumPy | basic |
| py3-pandas | Python3 pandas | basic |
| py3-pycodestyle | Python3 pycodestyle | basic |
| py3-pydocstyle | Python3 pydocstyle | basic |
| python3-tkinter | Python3 Tk | basic |
| R | R statistical computation and graphics system (GNU) | full |
| ruby | Ruby interpreter | standard |
| rust | Rust compiler | standard |
| racket | Scheme interpreter | standard |
| sqlite | SQL interpreter | basic |
php83-sqlite3
php82-sqlite3
php81-sqlite3
php8-sqlite3
|
Sqlite for PHP
|
basic
|
| openssl | SSL library | minimum |
| openssl-dev | SSL library | minimum |
| tcl | TCL interpreter | standard |
| valgrind | Valgrind tool | standard |
| iverilog | Verilog compiler | full |
| tigervnc | VNC server | minimum |
| firefox | Web browser | full |
fluxbox
metacity
openbox
|
Window manager
|
minimum
|
| xrdb | X resource manager | minimum |
| xorg-server | X system | minimum |
| xterm | xterm | minimum |
Using npm package manager
| Package name | Description |
|---|---|
| typescript | TypeScript |
| sass | Sass |
The system also asks if you wish to install Kotlin and JGrasp without using a package manager. JGrasp allows debugging Java using a GUI interface.
3.14. VPL Jail System Downloader and Installer/Updater (Experimental)¶
The script, download-install-vpl-sh, simplifies the process of downloading,
installing, and updating the VPL Jail System directly from the official GitHub repository.
This tool is recommended for both initial installations and upgrades.
Key Features:
- Automatic Version Detection: Installs or updates to the latest available release by default.
- Non-interactive Operation: Default installation is non-interactive,
with
fullandstartoptions enabled. - Smart Update Logic: Will not reinstall the same version or perform a downgrade unless explicitly forced.
- Custom Installer Options: Supports all local installer options (see
install-vpl-sh helpfor details). - Flexible Version Targeting: Allows installation of a specific version if required.
- No Downgrade or Reinstall: Prevents unnecessary reinstallation or downgrades, unless
force_updateis used.
3.14.1. Usage¶
./download-install-vpl-sh [OPTIONS]
Options
helpDisplay this help message and exit.version [VERSION]Specify the version to install or update to. Example:version V4.0.1force_updateForce installation or update to the specified version, even if it is the currently installed version or a lower version.local installer opsAny options accepted by the underlying installer script (install-vpl-sh). See./install-vpl-sh helpfor a full list.
3.14.2. Examples¶
Install or update to the latest version (non-interactive, default options):
./download-install-vpl-sh
Install a specific version (if your system is running an older version):
./download-install-vpl-sh version V4.0.1
Force a reinstallation or downgrade to a specific version:
./download-install-vpl-sh force_update version V4.0.1
Pass custom options to the installer (for advanced installations):
./download-install-vpl-sh version V4.0.4 minimum noninteractive
3.14.3. Notes and Recommendations¶
The script automatically fetches the latest or specified VPL Jail System release from the official GitHub repository: https://github.com/jcrodriguez-dis/vpl-jail-system
By default, the script performs a full installation and starts the VPL Jail System service. Use installer options (e.g.,
minimum,basic,standard,full,noninteractive,start) to tailor the process to your environment.For a complete list of local installer options, see the documentation for
install-vpl-shor run:./install-vpl-sh helpThe
force_updateoption is required if you need to reinstall the same version or perform a downgrade.The installer supports most modern Linux distributions (tested on Alpine, Ubuntu, Debian, Fedora) and multiple package managers (APT, DNF, APK, and YUM as of v4.0.4).
3.14.4. Troubleshooting¶
If you encounter permission issues, ensure
download-install-vpl-shis executable:chmod +x download-install-vpl-sh