The training portal
Every Learn ladder is also a workshop on the training portal, https://learn.selfhostedcloud.org. A session there is a lab made for you in your own Hetzner Cloud project: the ladder’s machines, with SHC installed and nothing initialized, created when the session starts and deleted when it ends. You prepare no machines and bring no licence; the machines bill to your project while the session runs.
An account
Section titled “An account”The portal asks you to sign in before any workshop opens, with your Selfhosted Cloud account and never with a password of its own. Open https://my.selfhostedcloud.org/learn and sign in, or press Create account there to make one.
The Learn screen lists every ladder. Any account can run the free part of learn-app, its first pages on one machine. A ladder marked as part of a full track opens once the account holds that track.
Your cloud
Section titled “Your cloud”A new session’s page asks for a Hetzner Cloud API token with Read & Write permission, from the project the lab should run in. The training portal checks the token, makes the lab’s machines with it, and keeps it only until those machines are deleted. End session on the page deletes them at once; otherwise they go when the session’s time is up.
In the browser
Section titled “In the browser”Press Start on a ladder. The pages are on the left and a terminal tab per node on the right. A click on a command block runs it in its node’s tab.
In your terminal
Section titled “In your terminal”shc workshop opens the same workshop in tmux on your own machine, the pages
on the left and a tab per node on the right. It needs shc, tmux and ssh
there.
$ shc workshop learn-appThe first run prints the portal’s sign-in address and opens it in your
browser. Sign in there, or come straight back if the browser is signed in
already. No password is typed in the terminal. The command then finds your
open session of that workshop, or starts one when you have none, prints
attached to session with its name, and opens tmux. A new session takes a
few minutes while its machines boot.
Selecting a command block in tmux, with a mouse click or with Enter, runs it
in its node’s tab, as a click does in the browser. A block that needs a
value an earlier command printed is typed and waits there for you to put the
value in and press Enter. A block you have run carries a + in front of its
node’s name; one that could not be sent carries an x, and the line at the
foot of the pages says why.
One session, two views
Section titled “One session, two views”The browser and the terminal show one session. Each node tab is a single terminal that both of them share, so a command typed in either shows in both, and so does its output. Start in the browser and attach from the terminal, or the other way round, and close either without ending the session.
A session belongs to the account that started it, and the portal gives a session’s key to its owner only.
The portal runs a set number of sessions at a time. When it has no room it
says so on its catalog page, and shc workshop stops with X503720WKSFUL.
What it keeps on your machine
Section titled “What it keeps on your machine”shc workshop keeps a token for the portal, and for each session it
attaches to an ssh config and the session’s own key, under
~/.config/shc/workshop. Nothing is written to ~/.ssh. A run after a
session has ended removes that session’s files. To sign out and remove all
of it:
$ shc workshop logoutIt prints signed out of https://learn.selfhostedcloud.org.
Another portal
Section titled “Another portal”--portal names a portal of your own, and so does SHC_WORKSHOP_PORTAL in
the environment. Sign out of it with the same flag:
$ shc workshop learn-app --portal https://learn.example.com$ shc workshop logout --portal https://learn.example.comMachines of your own
Section titled “Machines of your own”With --local the tabs open on machines already in your own ssh config, as
Host node1, node2 and so on, with no portal and no sign-in:
$ shc workshop cluster --localThe Learn index lists the ladders.