Commit graph

14 commits

Author SHA1 Message Date
Zbigniew Jędrzejewski-Szmek e8e581bf25 Report about syntax errors with metadata
The information about the unit for which files are being parsed
is passed all the way down. This way messages land in the journal
with proper UNIT=... or USER_UNIT=... attribution.

'systemctl status' and 'journalctl -u' not displaying those messages
has been a source of confusion for users, since the journal entry for
a misspelt setting was often logged quite a bit earlier than the
failure to start a unit.

Based-on-a-patch-by: Oleksii Shevchuk <alxchk@gmail.com>
2013-04-17 00:09:16 -04:00
Zbigniew Jędrzejewski-Szmek c1b6628d64 core: log a few more things under UNIT=... 2013-04-17 00:09:16 -04:00
Zbigniew Jędrzejewski-Szmek d3b6d0c21e fileio: in envfiles, do not skip lines following empty lines
https://bugs.freedesktop.org/show_bug.cgi?id=63477
2013-04-13 20:24:39 -04:00
Lennart Poettering f73141d765 shared: rework env file reader
Implement this with a proper state machine, so that newlines and
escaped chars can appear in string assignments. This should bring the
parser much closer to shell.
2013-04-03 20:12:57 +02:00
Zbigniew Jędrzejewski-Szmek ad88e758d1 Fix typos of /etc/systemd/systemd
<Lekensteyn> The 198 announcement mentions
             "/etc/systemd/systemd/foobar.service.d/*.conf", is that a
             typo? I only have a /etc/systemd/system/. Is there a
             manpage describing this new feature?
2013-03-09 18:56:31 -05:00
Harald Hoyer a5c32cff1f honor SELinux labels, when creating and writing config files
Also split out some fileio functions to fileio.c and provide a SELinux
aware pendant in fileio-label.c

see https://bugzilla.redhat.com/show_bug.cgi?id=881577
2013-02-14 16:19:38 +01:00
Zbigniew Jędrzejewski-Szmek a3aa7ee6ff tests: add test for continuation lines with comments 2013-02-13 01:05:28 -05:00
Zbigniew Jędrzejewski-Szmek 7742f7e999 tests: add test for install_full_printf() 2013-01-29 19:01:41 -05:00
Zbigniew Jędrzejewski-Szmek b989350563 util: modernization and test for load_env_file 2013-01-18 11:06:53 -05:00
Zbigniew Jędrzejewski-Szmek 0f67f1efae core: lift restriction on order of - and @ in ExecStart 2012-11-15 16:01:22 +01:00
Oleksii Shevchuk 7e1a84f552 core: interpret \; token in ExecStart as escaped ;
Some commands (like 'find') take a semicolon as separate arg. With
current parser implementation there is no way to pass one.

Patch adds token \;
2012-11-15 16:01:10 +01:00
Zbigniew Jędrzejewski-Szmek 2c5417ade0 tests: add tests for config_parse_exec 2012-11-15 16:00:45 +01:00
Zbigniew Jędrzejewski-Szmek d5891fdacf install: treat non-existent directory as empty
When looking for symlinks, it doesn't make sense to error-out if
the directory is missing. The user might delete an empty directory.

This check caused test-unit-file to fail when run before installation.
2012-09-16 14:00:25 +02:00
Lennart Poettering b5b46d5995 when determining unit file list, include invalid unit names in an "invalid" state 2012-09-11 01:14:25 +02:00