Skip to content

Linux Desktop

Give each student a full Linux desktop in the browser, with a web browser, a terminal, and the files you set up.

What a Linux Desktop is

A Linux Desktop puts a whole Linux computer next to your instructions, in the browser. Students get windows, a file manager, a web browser, and a terminal, with nothing to install. Use it when a lesson needs more than a code editor: a graphical program, a browser, or networking and security tools.

Each student gets their own desktop. It starts with the files in your desktop's home folder.

What's on it

  • Firefox, a terminal, a file manager, and a text editor.
  • Python 3 with pip, Node.js with npm, git, and compilers for C and C++.
  • Networking and security tools: nmap, netcat, Wireshark and tshark, sqlmap, gobuster, hydra, John the Ripper, hashcat, and aircrack-ng.

Plans

You can create a Linux Desktop on any plan. Students can open it when the course has Pro, or Core with the Cloud-based labs add-on. Until then, the editor shows a note saying so.

Create a Linux Desktop

Create a Linux Desktop4 steps
Screen for step 1: Choose + on a moduleScreen for step 2: Give the page a title
Interactive walkthrough
Create a Linux Desktop
Give each student a full Linux desktop in the browser, with the files you set up.
  1. In the course outline, choose + on a module.
  2. Give the page a title.
  3. Choose Cloud-based Lab.
  4. Under Choose an environment, choose Linux Desktop.

The page opens in the editor, with your instructions on the left and the desktop on the right.

Set up the starting files

  1. Choose Open desktop. It takes a moment to start.
  2. Put the files students should start with in the home folder. Make folders, download files in Firefox, or use Upload files to desktop at the top right of the desktop pane.
  3. Save your files, then publish the page.

Publishing asks you to confirm, because it stops your desktop. Save your work first: running programs and unsaved changes are lost. Students get a copy of your home folder the first time they open the desktop.

Only the home folder is copied. Software you install for the whole system, for example with sudo apt install, isn't. Put scripts, data, and downloaded programs in the home folder instead.

The whole home folder is copied, including hidden files such as shell history and saved keys. To leave files out, list them in ~/.curacourse/starterignore, one pattern per line, like a .gitignore file. See customize the code environment.

Change the files later

Make your changes and publish again. Students who haven't opened the desktop yet get the new files. Students who already opened it keep their own copy. They can choose ⋯ → Reset to Template to get your latest files, but that replaces their work.

Work in the desktop

The buttons at the top right of the desktop pane, next to the Workspace tab, are:

ButtonWhat it does
Copy from desktopCopies the text you copied inside the desktop to your own computer's clipboard.
Paste text to desktopPastes the text on your computer's clipboard into the desktop. Some characters, such as emoji, can't be pasted yet.
Copy screenshot to clipboardCopies a picture of the desktop, for example to paste into an answer.
Upload files to desktopAdds files from your computer, up to 10 files and 50 MB at a time.
⋯ (Desktop options)Stop, Restart, Open in new tab, Fullscreen, and, for students, Reset to Template.

Uploaded files go in the home folder.

Fullscreen fills your screen with the desktop and these buttons. Press Esc to leave it.

When the desktop stops

Your files in the home folder are kept when the desktop stops. Running programs aren't.

  • Without activity: the desktop stops after about 3 minutes. Moving the mouse or typing in the desktop counts. Shortly before it stops you'll see Your machine stops in 30 seconds. Choose Keep running to keep it going.
  • After 2 hours: a desktop always stops 2 hours after it started. You'll see a warning 5 minutes before.
  • Stop: choose ⋯ → Stop when you're done.

To start again, choose Open desktop.

Restart turns the desktop off and on again. Saved files are kept. Use it if the desktop freezes.

Reset to Template gives a student a fresh copy of your files and restarts the desktop. It deletes their files, so they should copy anything they want to keep first.

Grading

Grade a Linux Desktop like any other page: with manual criteria, AI criteria, or code tests. Code tests run against the student's files as they were when they submitted, from their home folder. See manual, AI, and code grading criteria.

If the page has code tests, students must open the desktop at least once before they submit. Otherwise they see Open the desktop before submitting so your files can be graded.

To let students check their work before they submit, add an Instant Feedback block to the instructions and bind it to your code tests. Check Answer runs the tests on the files in the student's home folder at that moment. It doesn't submit the page.

Review student work

Open a student's desktop from the learner list. When a student submits, you see their files as they were at that moment.

For students

  1. Open the page and read the instructions.
  2. Choose Open desktop. The first time, it starts with your instructor's files. After that, it's your own copy.
  3. Save your work in the home folder. Files saved there stay between sessions.
  4. When you're done, choose Submit at the top of the page. See submit your work.

If something goes wrong

  • Desktop disconnected: choose Reconnect.
  • "This desktop hasn't been set up yet": the instructor hasn't opened the desktop in the editor and published. Instructors: open the desktop in the editor, then publish again.
  • "Lesson published without desktop starter files": open the desktop in the editor and publish again.
  • "Open the desktop before checking so your files can be graded": choose Open desktop, save your work, then check again.
  • The desktop is stuck or very slow: choose ⋯ → Restart.
  • Paste doesn't work: allow clipboard access when your browser asks, and check the desktop is connected.
  • Still stuck: contact support with the course and page name.