← Servers, deploying and APIs

Lesson 5 of 20 · Try it · 45 min

1.5 Hands-on: updates, your own user and a key

Steps

  1. Log in as root (item 1.3) and run apt update && apt upgrade -y.
  2. Make your own user and give it sudo (item 1.4).
  3. On your laptop, make a key with ssh-keygen -t ed25519 and copy it to the server.
  4. In a new terminal window, log in as your user: ssh <you>@<your IP>. It should not ask for the server password.
  5. Run sudo apt update. It asks for your user's password once. That's sudo working.
  6. In Lynk, open Health. Check: the agent is reporting, Automatic security updates and Password-guessing protection are on, and there are no security updates waiting.
  7. Take a screenshot of your terminal showing you logged in as your own user, and of Health.

Check your work: you log in as your own user without the server password, and Health shows the agent reporting.

Try it in Lynk

Now do it yourself. When you're done, come back here and mark this lesson done.

Sign in to try it
Next lesson

Sign in to save your progress and earn the certificate.

1.4 Set your server up safely