Skip to content

Commit c51da86

Browse files
committed
Editorial changes.
1 parent 7dc68b5 commit c51da86

File tree

2 files changed

+65
-57
lines changed

2 files changed

+65
-57
lines changed

webpages/auto-login.md

Lines changed: 39 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -7,33 +7,34 @@ layout: vm-operator
77

88
*Since 4.0.0*
99

10-
When a user logs in on the web GUI, he has already authenticated with the
11-
VM-Operator. Depending on the environment, it may be tedious to log in again
12-
on the guest. The VM-Operator therefore supports automatic login on the guest
13-
operating system which can streamline the user experience by eliminating
14-
the need for multiple logins. This requires, however, some support from
15-
the guest OS.
10+
When users log into the web GUI, they have already authenticated with the
11+
VM-Operator. In some environments, requiring an additional login on the
12+
guest OS can be cumbersome. To enhance the user experience, the VM-Operator
13+
supports automatic login on the guest operating system, thus eliminating
14+
the need for multiple logins. However, this feature requires specific
15+
support from the guest OS.
1616

1717
## Prepare the VM
1818

19-
Automatic login requires an agent in the guest OS. Similar to QEMU's
20-
standard guest agent, the VM-Operator agent communicates with the host
21-
through a tty device (`/dev/virtio-ports/org.jdrupes.vmop_agent.0`). On a modern
22-
Linux system, the device is detected by `udev` which triggers the start
23-
of a systemd service.
19+
Automatic login requires an agent running inside the guest OS. Similar
20+
to QEMU's standard guest agent, the VM-Operator agent communicates with
21+
the host via a tty device (`/dev/virtio-ports/org.jdrupes.vmop_agent.0`). On
22+
modern Linux systems, `udev` can detect this device and trigger the start
23+
of an associated systemd service.
2424

25-
Sample configuration files can be found
25+
Sample configuration files for a VM-Operator agent are available
2626
[here](https://github.com/mnlipp/VM-Operator/tree/main/dev-example/vmop-agent).
2727
Copy
2828

29-
* `99-vmop-agent.rules` to `/usr/local/lib/udev/rules.d/99-vmop-agent.rules`,
30-
* `vmop-agent` to `/usr/local/libexec/vmop-agent` and
31-
* `vmop-agent.service` to `/usr/local/lib/systemd/system/vmop-agent.service`.
29+
* `99-vmop-agent.rules` `/usr/local/lib/udev/rules.d/99-vmop-agent.rules`,
30+
* `vmop-agent` `/usr/local/libexec/vmop-agent` and
31+
* `vmop-agent.service` `/usr/local/lib/systemd/system/vmop-agent.service`.
3232

33-
Note that some of the target directories do not exist by default and have to
34-
be created first. Don't forget to run `restorecon` on systems with SELinux.
33+
Some of these target directories may not exist by default and must be
34+
created manually. If your system uses SELinux, run `restorecon` to apply
35+
the correct security contexts.
3536

36-
Enable everything:
37+
Enable the agent:
3738

3839
```console
3940
# systemctl daemon-reload
@@ -44,41 +45,43 @@ Enable everything:
4445

4546
## The VM operator agent
4647

47-
Communication with the VM-Operator agent follows the pattern established
48-
by protocols such as SMTP and FTP. The agent must handle the commands
49-
"`login <username>`" and "`logout`". In response to these commands, the agent
50-
sends back lines that start with a three digit number. The first digit
51-
determines the type of message: "1" for informational, "2" for success
52-
"4" and "5" for errors. The second digit provides information about the
53-
category that the response relates to. The third digit is specific to
54-
the command.
48+
Communication with the VM-Operator agent follows the pattern established by
49+
protocols such as SMTP and FTP. The agent must handle the commands
50+
"`login <username>`" and "`logout`" on its input. In response to
51+
these commands, the agent sends back lines that start with a three
52+
digit number. The first digit determines the type of message: "1" for
53+
informational, "2" for success and "4" or "5" for errors. The second
54+
digit provides information about the category that a response relates
55+
to. The third digit is specific to the command.
5556

56-
While this describes the general pattern, the only response code that
57-
the runner evaluates are:
57+
While this describes the general pattern, the [runner](runner.html)
58+
only evaluates the following codes:
5859

5960
| Code | Meaning |
6061
| ---- | ------- |
6162
| 220 | Sent by the agent on startup |
6263
| 201 | Login command executed successfully |
6364
| 202 | Logout command executed successfully |
6465

65-
The sample script is written for the gnome desktop environment. It assumes
66-
that gdm is running as a service by default. On receiving the login command,
67-
it stops gdm and starts a gnome-session for the given user. On receiving the
68-
logout command, it terminates the session and starts gdm again.
66+
The provided sample script is written for the gnome desktop environment.
67+
It assumes that GDM is running as a service by default. When the agent
68+
receives a login command, it stops GDM and starts a gnome-session for
69+
the specified user. Upon receiving the logout command, it terminates
70+
the session and starts GDM again.
6971

7072
No attempt has been made to make the script configurable. There are too
7173
many possible options. The script should therefore be considered as a
72-
starting point that you can adapt to your needs.
74+
starting point that you may need to adapt to your specific needs.
7375

74-
The sample script also creates new user accounts if a user does not exist
75-
yet. The idea behind this is further explained in the
76+
In addition to starting the desktop for the logged in user, the sample
77+
script automatically creates user accounts if they do not already exist.
78+
The idea behind this behavior is further explained in the
7679
[section about pools](pools.html#vm-pools).
7780

7881
## Enable auto login for a VM
7982

8083
To enable auto login for a VM, specify the user to be logged in in the VM's
8184
definition with "`spec.vm.display.loggedInUser: user-name`". If everything has been
8285
set up correctly, you should be able to open the console and observe the
83-
change from gdm's login screen to the user's desktop when updating the
86+
transition from GDM's login screen to the user's desktop when updating the
8487
VM's spec.

webpages/pools.md

Lines changed: 26 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,17 @@ layout: vm-operator
77

88
*Since 4.0.0*
99

10-
Not all VMs are replacements for carefully maintained individual PCs.
11-
In many workplaces, a standard configuration can be used where
12-
user-specific data is kept in each user's home directory on a shared
13-
file system. In such cases, an alternative to providing individual
14-
PCs is to offer a pool of VMs and allocate them from the pool to users
15-
as needed.
10+
Not all VMs are defined as replacements for carefully maintained
11+
individual PCs. In many workplaces, a standardardized VM configuration
12+
can be used where all user-specific data is stored in each user's home
13+
directory. By using a shared file system for home directories, users
14+
can login on any VM and find themselves in their personal
15+
environment.
16+
17+
If only a subset of users require access simultaneously, this makes it
18+
possible to define a pool of standardardized VMs and dynamically assign
19+
them to users as needed, eliminating the need to define a dedicated VM
20+
for each user.
1621

1722
## Pool definitions
1823

@@ -39,18 +44,18 @@ spec:
3944
```
4045
4146
The `retention` specifies how long the assignment of a VM from the pool to
42-
a user is retained after the user closes the console. This allows a user
43-
to interrupt his work for this period of time without risking that
44-
another user takes over the VM. The time is specified as
47+
a user remains valid after the user closes the console. This ensures that
48+
a user can resume work within this timeframe without the risk of another
49+
user taking over the VM. The time is specified as
4550
[ISO 8601 duration](https://en.wikipedia.org/wiki/ISO_8601#Durations).
4651

4752
Setting `loginOnAssignment` to `true` triggers automatic login of the
4853
user (as described in [section auto login](auto-login.html)) when
49-
the VM is assigned. The `permissions` property defines what a user can
50-
do with a VM assigned to him.
54+
the VM is assigned. The `permissions` property specifies the actions
55+
that users or roles can perform on assigned VMs.
5156

5257
VMs become members of one (or more) pools by adding the pool name to
53-
property `spec.pools` (an array of strings), e.g.:
58+
the `spec.pools` array, as shown below:
5459

5560
```yaml
5661
apiVersion: "vmoperator.jdrupes.org/v1"
@@ -69,26 +74,26 @@ provide access to a pool instead of to a specific VM.
6974

7075
![VM Access configuration](ConfigAccess-preview.png){: width="500"}
7176

72-
Assignment happens when the "start" icon is pushed. If the assigned VM
73-
is not running, it will also be started. The assigned VM's name is
74-
shown in the widget above the action icons.
77+
Assignment happens when the "Start" icon is clicked. If the assigned VM
78+
is not already running, it will be started automatically. The assigned
79+
VM's name apears in the widget above the action icons.
7580

7681
![VM Access via pool](PoolAccess-preview.png)
7782

7883
Apart from showing the assigned VM, the widget behaves in the same way
79-
as it does when configured to access a specific VM.
84+
as when configured for accessing a specific VM.
8085

81-
## Requirements on the guest
86+
## Guest OS Requirements
8287

83-
Some provisions must be made on the guest to ensure that VMs from
84-
pools work as expected.
88+
To ensure proper functionality when using VM pools, certain requirements
89+
must be met on the guest OS.
8590

8691
### Shared file system
8792

88-
Mount a shared file system as home file system on all VMs in the pool.
93+
All VMs in the pool must mount a shared file system as the home directory.
8994
When using the
9095
[sample agent](https://github.com/mnlipp/VM-Operator/tree/main/dev-example/vmop-agent),
91-
the filesystem must support POSIX file access control lists (ACLs).
96+
the file system must support POSIX file access control lists (ACLs).
9297

9398
### User management
9499

0 commit comments

Comments
 (0)