The Webadmin and the Command Line
Outcome: faced with any administrative
job, you can name the tool for it — the
webadmin for clicking, the yunohost
command for scripting — and you know the
command families by name, because they
are listed here from the program's own
command map.
A YunoHost server has two front doors.
The webadmin is a web interface —
sign in with an administrator's account
at https://your.domain.tld/yunohost/admin
(or by the machine's IP address, which
works for the webadmin even when DNS is
still being fixed) — and every routine
job has a page there: users, domains,
applications, backups, diagnosis,
firewall, services. The yunohost
command line does the same jobs from
an SSH session, and a few the webadmin
cannot: some backup features, group mail
aliases, and adding SSH keys, per the
documentation, are command-line only.
They are not rivals. Chapter 2 explained the shape: both sit on the same API, so an action is an action. Use the web for browsing and first attempts — it shows you the state of things as it works — and the command line for repetition, repair, and anything you want to write down and reuse.
The command map
The full yunohost command surface, from
the actionsmap.yml file in the core
source (the same map the API itself
uses), grouped the way you will use it:
People and access
yunohost user— list, create, delete, update, info, and export/import of users, with sub-families:yunohost user group— groups, including their mail aliases;yunohost user permission— who may use which app or service;yunohost user ssh— users' SSH keys.
Places and names
yunohost domain— list, info, add, remove, and choose the main domain, with sub-families:yunohost domain dns—suggestprints the recommended DNS records;pushapplies them where the registrar supports it;yunohost domain cert— certificate status, install, renew;yunohost domain dyndns— the free-domain subscription commands;yunohost domain config.
Applications
yunohost app—catalogandsearchto browse,install,remove,upgrade,info,change-url,setting, plusapp actionfor an app's own extra actions andapp configfor its settings panel.
The safety kit
yunohost backup— create, restore, list, info, download, delete (chapter 11);yunohost diagnosis— list, show, run, andignore/unignorefor findings you have decided are not problems (chapter 10);yunohost log— list, show andsharethe operation logs YunoHost keeps of its own actions; when something fails, the log it offers to share is the thing the support forum will ask for;yunohost hook— the extension points of chapter 2, for advanced use.
The machine itself
yunohost service— start, stop, restart, status and logs for the underlying services (nginx, postfix, dovecot and friends);yunohost firewall— list, allow, disallow, open, close, reload — the port rules of chapter 12;yunohost settings— the global settings (the source groups them under security, email and misc);yunohost tools— the toolbox:postinstall(chapter 4),updateandupgrade(chapter 12),regen-confto regenerate configuration files,migrationsfor the guided jumps between major versions, plusshutdownandreboot;yunohost storage disk— what disks the machine can see;yunohost dyndns— dynamic DNS updates for home connections.
Working habits worth forming
- Ask for help from the tool itself.
Every family answers
--help(yunohost user --help, in the documentation's example), and the help is generated from the same command map this chapter lists, so it cannot drift far from the truth. - Prefer the command line when a job will be repeated. The webadmin is a fine place to install your first app; the sixth household member's account is a command you will be glad you wrote down.
- Expect the two doors to agree. If
the webadmin and the command line ever
seem to disagree about the state of
the server, believe the diagnosis tool
(chapter 10) and the operation logs —
and regenerate the configuration with
yunohost tools regen-confbefore hand-editing anything, because YunoHost manages those files and will overwrite hand edits on its own schedule.