mirror of https://github.com/fairyglade/ly.git
templated systemd file
This commit is contained in:
parent
3d8d8d67df
commit
6d3808553e
|
@ -111,7 +111,7 @@ fn installsystemd(self: *std.Build.Step, progress: *std.Progress.Node) !void {
|
|||
var service_dir = std.fs.openDirAbsolute("/usr/lib/systemd/system", .{}) catch unreachable;
|
||||
defer service_dir.close();
|
||||
|
||||
try std.fs.cwd().copyFile("res/ly.service", service_dir, "ly.service", .{ .override_mode = 644 });
|
||||
try std.fs.cwd().copyFile("res/ly@.service", service_dir, "ly@.service", .{ .override_mode = 644 });
|
||||
}
|
||||
|
||||
fn installopenrc(self: *std.Build.Step, progress: *std.Progress.Node) !void {
|
||||
|
|
|
@ -92,9 +92,10 @@ Install Ly and the provided systemd service file
|
|||
# zig build installsystemd
|
||||
```
|
||||
|
||||
Enable the service
|
||||
Enable the service (this will spawn on tty2 and tty9)
|
||||
```
|
||||
# systemctl enable ly.service
|
||||
# systemctl enable ly@tty2.service
|
||||
# systemctl enable ly@tty9.service
|
||||
```
|
||||
|
||||
If you need to switch between ttys after Ly's start you also have to
|
||||
|
@ -103,6 +104,8 @@ disable getty on Ly's tty to prevent "login" from spawning on top of it
|
|||
# systemctl disable getty@tty2.service
|
||||
```
|
||||
|
||||
If you have multiple ttys setup with systemd, the tty option will be used as your default tty.
|
||||
|
||||
### OpenRC
|
||||
**NOTE**: On Gentoo, Ly will disable the `display-manager-init` service in order to run.
|
||||
|
||||
|
|
|
@ -1,17 +1,18 @@
|
|||
[Unit]
|
||||
Description=TUI display manager
|
||||
Description=TUI display manager (on %I)
|
||||
After=systemd-user-sessions.service plymouth-quit-wait.service
|
||||
After=getty@tty2.service
|
||||
Conflicts=getty@tty2.service
|
||||
After=getty@%I.service
|
||||
Conflicts=getty@%I.service
|
||||
|
||||
[Service]
|
||||
Type=idle
|
||||
ExecStart=/usr/bin/ly
|
||||
StandardError=journal
|
||||
StandardInput=tty
|
||||
TTYPath=/dev/tty2
|
||||
TTYPath=/dev/%I
|
||||
TTYReset=yes
|
||||
TTYVHangup=yes
|
||||
|
||||
[Install]
|
||||
Alias=display-manager.service
|
||||
WantedBy=multi-user.target
|
||||
# Alias=display-manager.service
|
Loading…
Reference in New Issue