Skip to content

Commit

Permalink
ncm-systemd: Add path support
Browse files Browse the repository at this point in the history
Adds support for [path] directives. This is useful for credential
handling, where we can detect the template file changing and trigger a
one-shot service.
  • Loading branch information
DavidFair committed Apr 13, 2023
1 parent e0300c4 commit 1e21631
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions ncm-systemd/src/main/pan/components/systemd/schema.pan
Original file line number Diff line number Diff line change
Expand Up @@ -355,6 +355,24 @@ type ${project.artifactId}_unitfile_config_socket = {
true;
};

@documentation{
the [Path] section
https://www.freedesktop.org/software/systemd/man/systemd.path.html
}
type ${project.artifactId}_unitfile_config_path = {
'PathExists' ? absolute_file_path
'PathExistsGlob' ? string
'PathChanged' ? absolute_file_path
'PathModified' ? absolute_file_path
'DirectoryNotEmpty' ? absolute_file_path

'Unit' ? string
'MakeDirectory' ? boolean
'DirectoryMode' ? type_octal_mode
'TriggerLimitIntervalSec' ? string
'TriggerLimitBurst' ? long(0..)
}

@documentation{
the [mount] section
http://www.freedesktop.org/software/systemd/man/systemd.mount.html
Expand Down Expand Up @@ -421,6 +439,7 @@ type ${project.artifactId}_unitfile_config = {
'socket' ? ${project.artifactId}_unitfile_config_socket
'mount' ? ${project.artifactId}_unitfile_config_mount
'automount' ? ${project.artifactId}_unitfile_config_automount
'path' ? ${project.artifactId}_unitfile_config_path
'timer' ? ${project.artifactId}_unitfile_config_timer
'unit' ? ${project.artifactId}_unitfile_config_unit
};
Expand Down

0 comments on commit 1e21631

Please sign in to comment.