diff --git a/docs/client.md b/docs/client.md index 5c2f28c47a08dc2b016e075d9d270e246c375733..f49d5c072150473ab08b01fbce473a4bfd8960f5 100644 --- a/docs/client.md +++ b/docs/client.md @@ -146,9 +146,15 @@ usercreate Creates a user. userdel Deletes one or more users. Requires USER_DESTROY user capability. +userresetpwd Reset password for one or more users. + Requires USER_RESETPWD user capability. + usersetcaps Sets a user's capabilities. Requires USER_SET_CAPS user capability. +userunlock Unlocks one or more users. + Requires USER_UNLOCK user capability. + ═════╡ TEMPLATE commands ╞═════════════════════════════════════════════════════════════════ tplcreate Creates a template from an existing VM. @@ -181,7 +187,7 @@ vmcreds2pdf Creates a PDF with the credentials required to attach to run If not the VM's owner: requires VM_ATTACH VM access capability or VM_ATTACH_ANY user capability. vmcreds2csv Creates a CSV file with the credentials required to attach to running VMs. - The written CSV file contains 4 columns: VM ID;VM name;port;password + The written CSV file contains 3 columns: VM ID;VM name;password If not the VM's owner: requires VM_ATTACH VM access capability or VM_ATTACH_ANY user capability. vmdel Deletes one or more VMs. @@ -302,27 +308,27 @@ First, you need to create the VM that will be used by your students during the e - student: unprivileged user (doesn't have a sudo access); its password is "student" - nexus: privileged user (access to sudo); its password is "nexus" -1. Create the VM based on the chosen template. Let's say you want the VM to be named "Exam ProgSys Oct2022" and you want it to have 2 CPUs, 3GB RAM and access to the Internet (for now): +1. Create the VM based on the chosen template. Let's say you want the VM to be named "Exam ProgSys 06.2024" and you want it to have 2 CPUs, 3GB RAM and access to the Internet (for now): ``` - vmcreate "Exam ProgSys Oct2022" 2 3000 user none 6d735b5d-1ff7-4931-b6f7-0b8eb070d7bd + vmcreate "Exam ProgSys 06.2024" 2 3000 user none 6d735b5d-1ff7-4931-b6f7-0b8eb070d7bd ``` This command displays the name and ID of the created VM(s): ``` - Created VM "Exam ProgSys Oct2022" | 148ea20e-9c45-4bd1-a670-f18312d436b8 + Created VM "Exam ProgSys 06.2024" | 148ea20e-9c45-4bd1-a670-f18312d436b8 ``` 1. Now that the VM is created, you need to start it, connect to it, and configure it to fit your needs. First, start it by starting any VM matching the following expression (matching is case-insensitive - you can also start it by specifying its unique VM ID): ``` - vmstart "exam progsys oct2022" + vmstart "exam progsys 06.2024" ``` This command displays the name of the started VM(s): ``` - Started VM "Exam ProgSys Oct2022" + Started VM "Exam ProgSys 06.2024" ``` 1. Attach to the VM in order to configure it to your needs: ``` - vmattach "exam progsys oct2022" + vmattach "exam progsys 06.2024" ``` alternatively, you could use the VM ID instead (this ensure any other possible name matches): ``` @@ -355,60 +361,60 @@ First, you need to create the VM that will be used by your students during the e <!-- 1. Add the exam' specific files. All files (questions, code, etc.) can be copied from your local machine to the VM with `vmimportdir`. However, this command requires the VM to be shutdown so make sure it's not running. Below, we copy the "exam" local directory into the VM's student user's Desktop (`/home/student/Desktop`). Note that it copies the directory along all its subdirectories and files: ``` - vmimportdir "exam progsys oct2022" exam /home/student/Desktop + vmimportdir "exam progsys 06.2024" exam /home/student/Desktop ``` The command displays the directory was copied successfully: ``` - Successfully copied "exam" into "/home/student/Desktop" in VM "Exam ProgSys Oct2022" + Successfully copied "exam" into "/home/student/Desktop" in VM "Exam ProgSys 06.2024" ``` --> -1. Now that the VM is ready for the exam, create a template from it. The template must be `private` as we don't want anyone else to access it. Let's choose "Exam ProgSys Oct2022" as the template name (template creation takes several minutes, the larger the VM, the longer). The first argument is the template's name and the last is the VM ID from which the template must be created (as displayed when the VM was created earlier): +1. Now that the VM is ready for the exam, create a template from it. The template must be `private` as we don't want anyone else to access it. Let's choose "Exam ProgSys 06.2024" as the template name (template creation takes several minutes, the larger the VM, the longer). The first argument is the template's name and the last is the VM ID from which the template must be created (as displayed when the VM was created earlier): ``` - tplcreate "Exam ProgSys Oct2022" private 148ea20e-9c45-4bd1-a670-f18312d436b8 + tplcreate "Exam ProgSys 06.2024" private 148ea20e-9c45-4bd1-a670-f18312d436b8 ``` This command displays details about the newly created template: ``` { "id": "0fb0b1f2-c72c-416e-961a-6bb802da89bb", - "name": "Exam ProgSys Oct2022", - "owner": "florent.gluck@hesge.ch", + "name": "Exam ProgSys 06.2024", + "owner": "janedoe@nexus.org", "access": "private" - "creationTime": "2022-10-25T16:42:17+01:00" + "creationTime": "2024-06-15T16:42:17+01:00" } ``` -1. You can now create the VMs for your 30 students using your new template (ID `0fb0b1f2-c72c-416e-961a-6bb802da89bb`). Let's say the base name for the 30 VMs to create is "Live Exam ProgSys Oct2022". You want the VMs to have: 2 CPUs, 3GB RAM and no network interface to forbid any potentiel network/Internet access. Create a CSV file, say `students.csv` with the names of your 30 students, one per line (single column file). Then, create the 30 VMs with: +1. You can now create the VMs for your 30 students using your new template (ID `0fb0b1f2-c72c-416e-961a-6bb802da89bb`). Let's say the base name for the 30 VMs to create is "Live Exam ProgSys 06.2024". You want the VMs to have: 2 CPUs, 3GB RAM and no network interface to forbid any potentiel network/Internet access. Create a CSV file, say `students.csv` with the names of your 30 students, one per line (single column file). Then, create the 30 VMs with: ``` - vmcreate "Live Exam ProgSys Oct2022" 2 3000 none none 0fb0b1f2-c72c-416e-961a-6bb802da89bb students.csv + vmcreate "Live Exam ProgSys 06.2024" 2 3000 none none 0fb0b1f2-c72c-416e-961a-6bb802da89bb students.csv ``` This command displays the list of created VMs: ``` - Created VM "Live Exam ProgSys Oct2022 <Alia Friedman>" | 74d8b83d-f59e-4129-bf68-af574968cf48 - Created VM "Live Exam ProgSys Oct2022 <Aria Doyle>" | f3047faa-2f15-4f47-b79f-9acc19751b6c - Created VM "Live Exam ProgSys Oct2022 <Avah Coffey>" | 3ebd56a2-2c1e-416c-9847-f80ee3efa1c1 - Created VM "Live Exam ProgSys Oct2022 <Briley Brady>" | 245fc5b2-b192-4b41-80be-2d39b5a2cef2 - Created VM "Live Exam ProgSys Oct2022 <Brooklyn Sweeney>" | a9bafd7e-28f0-4f37-8b90-5e3c82d4bbc5 - Created VM "Live Exam ProgSys Oct2022 <Cornelius Simmons>" | 40edb2b1-b4e9-4928-9dea-316ed834bf07 - Created VM "Live Exam ProgSys Oct2022 <Donovan Heath>" | 8ae5c9cd-16f3-4e02-a940-e4209a6d7010 - Created VM "Live Exam ProgSys Oct2022 <Ella Webster>" | 7d16f88f-afb1-4633-a646-57a9c87411d5 + Created VM "Live Exam ProgSys 06.2024 <Alia Friedman>" | 74d8b83d-f59e-4129-bf68-af574968cf48 + Created VM "Live Exam ProgSys 06.2024 <Aria Doyle>" | f3047faa-2f15-4f47-b79f-9acc19751b6c + Created VM "Live Exam ProgSys 06.2024 <Avah Coffey>" | 3ebd56a2-2c1e-416c-9847-f80ee3efa1c1 + Created VM "Live Exam ProgSys 06.2024 <Briley Brady>" | 245fc5b2-b192-4b41-80be-2d39b5a2cef2 + Created VM "Live Exam ProgSys 06.2024 <Brooklyn Sweeney>" | a9bafd7e-28f0-4f37-8b90-5e3c82d4bbc5 + Created VM "Live Exam ProgSys 06.2024 <Cornelius Simmons>" | 40edb2b1-b4e9-4928-9dea-316ed834bf07 + Created VM "Live Exam ProgSys 06.2024 <Donovan Heath>" | 8ae5c9cd-16f3-4e02-a940-e4209a6d7010 + Created VM "Live Exam ProgSys 06.2024 <Ella Webster>" | 7d16f88f-afb1-4633-a646-57a9c87411d5 ... ``` -1. The day of the exam, you'll have to start the 30 VMs and generate a PDF with the randomly generated credentials required to connect to each VM (a port number and a password, unique to each VM). To start the 30 VMs, run: +1. The day of the exam, you'll have to start the 30 VMs and generate a PDF with the randomly generated credentials required to connect to each VM (a password, unique to each VM). To start the 30 VMs, run: ``` vmstart "live exam progsys" ``` This command displays the list of started VMs: ``` - Started VM "Live Exam ProgSys Oct2022 <Alia Friedman>" - Started VM "Live Exam ProgSys Oct2022 <Aria Doyle>" - Started VM "Live Exam ProgSys Oct2022 <Avah Coffey>" - Started VM "Live Exam ProgSys Oct2022 <Briley Brady>" - Started VM "Live Exam ProgSys Oct2022 <Brooklyn Sweeney>" - Started VM "Live Exam ProgSys Oct2022 <Cornelius Simmons>" - Started VM "Live Exam ProgSys Oct2022 <Donovan Heath>" - Started VM "Live Exam ProgSys Oct2022 <Ella Webster>" + Started VM "Live Exam ProgSys 06.2024 <Alia Friedman>" + Started VM "Live Exam ProgSys 06.2024 <Aria Doyle>" + Started VM "Live Exam ProgSys 06.2024 <Avah Coffey>" + Started VM "Live Exam ProgSys 06.2024 <Briley Brady>" + Started VM "Live Exam ProgSys 06.2024 <Brooklyn Sweeney>" + Started VM "Live Exam ProgSys 06.2024 <Cornelius Simmons>" + Started VM "Live Exam ProgSys 06.2024 <Donovan Heath>" + Started VM "Live Exam ProgSys 06.2024 <Ella Webster>" ... ``` @@ -438,14 +444,14 @@ First, you need to create the VM that will be used by your students during the e ``` This command displays each exported file tree: ``` - Successfully exported /home/student/Desktop/exam from VM "Live Exam ProgSys Oct2022 <Alia Friedman>" into Live Exam ProgSys Oct2022 <Alia Friedman>.tar.gz - Successfully exported /home/student/Desktop/exam from VM "Live Exam ProgSys Oct2022 <Aria Doyle>" into Live Exam ProgSys Oct2022 <Aria Doyle>.tar.gz - Successfully exported /home/student/Desktop/exam from VM "Live Exam ProgSys Oct2022 <Avah Coffey>" into Live Exam ProgSys Oct2022 <Avah Coffey>.tar.gz - Successfully exported /home/student/Desktop/exam from VM "Live Exam ProgSys Oct2022 <Briley Brady>" into Live Exam ProgSys Oct2022 <Briley Brady>.tar.gz - Successfully exported /home/student/Desktop/exam from VM "Live Exam ProgSys Oct2022 <Brooklyn Sweeney>" into Live Exam ProgSys Oct2022 <Brooklyn Sweeney>.tar.gz - Successfully exported /home/student/Desktop/exam from VM "Live Exam ProgSys Oct2022 <Cornelius Simmons>" into Live Exam ProgSys Oct2022 <Cornelius Simmons>.tar.gz - Successfully exported /home/student/Desktop/exam from VM "Live Exam ProgSys Oct2022 <Donovan Heath>" into Live Exam ProgSys Oct2022 <Donovan Heath>.tar.gz - Successfully exported /home/student/Desktop/exam from VM "Live Exam ProgSys Oct2022 <Ella Webster>" into Live Exam ProgSys Oct2022 <Ella Webster>.tar.gz + Successfully exported /home/student/Desktop/exam from VM "Live Exam ProgSys 06.2024 <Alia Friedman>" into Live Exam ProgSys 06.2024 <Alia Friedman>.tar.gz + Successfully exported /home/student/Desktop/exam from VM "Live Exam ProgSys 06.2024 <Aria Doyle>" into Live Exam ProgSys 06.2024 <Aria Doyle>.tar.gz + Successfully exported /home/student/Desktop/exam from VM "Live Exam ProgSys 06.2024 <Avah Coffey>" into Live Exam ProgSys 06.2024 <Avah Coffey>.tar.gz + Successfully exported /home/student/Desktop/exam from VM "Live Exam ProgSys 06.2024 <Briley Brady>" into Live Exam ProgSys 06.2024 <Briley Brady>.tar.gz + Successfully exported /home/student/Desktop/exam from VM "Live Exam ProgSys 06.2024 <Brooklyn Sweeney>" into Live Exam ProgSys 06.2024 <Brooklyn Sweeney>.tar.gz + Successfully exported /home/student/Desktop/exam from VM "Live Exam ProgSys 06.2024 <Cornelius Simmons>" into Live Exam ProgSys 06.2024 <Cornelius Simmons>.tar.gz + Successfully exported /home/student/Desktop/exam from VM "Live Exam ProgSys 06.2024 <Donovan Heath>" into Live Exam ProgSys 06.2024 <Donovan Heath>.tar.gz + Successfully exported /home/student/Desktop/exam from VM "Live Exam ProgSys 06.2024 <Ella Webster>" into Live Exam ProgSys 06.2024 <Ella Webster>.tar.gz ... ``` @@ -661,10 +667,9 @@ export NEXUS_CERT=$(pwd)/ca-cert.isc-nexus-prod.pem --> The purpose of `nexus-exam` is to be used during live exam sessions. Students are provided with laptops configured to boot on dedicated USB keys. These USB keys feature a minimal Linux system that automatically run `nexus-exam` at boot time. 50 such USB keys have been created and are ready to be used. - The only thing that's necessary to use `nexus-exam` is to boot on one of the USB keys mentionned above. -To obtain these USB keys, please contact Florent Gluck at florent.gluck@hesge.ch. +Additionally, `nexus-exam` can also be ran by booting on PXE on the nexus-exam image available to any loaned laptop connected to a RJ45 câble in a classroom or office. Below is a screenshot of `nexus-exam`'s graphical interface: diff --git a/docs/img/nexus-exam.png b/docs/img/nexus-exam.png index 66fd93d6374f72a57d5376db407b19ccd057f454..b843ad2e26dc1b14239b4e3afd80d84906d823bf 100644 Binary files a/docs/img/nexus-exam.png and b/docs/img/nexus-exam.png differ diff --git a/docs/img/vmattach.jpg b/docs/img/vmattach.jpg index de1e77b1897b0e990469ad9e3000ed2557dc4a5b..e5efc5279d6676d12dbaf3e4170280ac8a2a1b42 100644 Binary files a/docs/img/vmattach.jpg and b/docs/img/vmattach.jpg differ diff --git a/docs/img/vmcred2pdf.png b/docs/img/vmcred2pdf.png index 3a0c8c9532110c76b0b4304bdb066c783e2ef719..9fbd071caabb7eb2879523db66c76f40982d30d9 100644 Binary files a/docs/img/vmcred2pdf.png and b/docs/img/vmcred2pdf.png differ