Bug 661291
Summary: | Quoted assignments in EnvironmentFile passed as one argument | ||
---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Miroslav Lichvar <mlichvar> |
Component: | systemd | Assignee: | Lennart Poettering <lpoetter> |
Status: | CLOSED UPSTREAM | QA Contact: | Fedora Extras Quality Assurance <extras-qa> |
Severity: | medium | Docs Contact: | |
Priority: | low | ||
Version: | rawhide | CC: | lpoetter, metherid, mhlavink, mschmidt, notting, plautrba |
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2011-01-05 15:19:17 UTC | Type: | --- |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: | |||
Bug Depends On: | |||
Bug Blocks: | 660206 |
Description
Miroslav Lichvar
2010-12-08 13:20:41 UTC
Quoting from systemd.service(5): "On top of that basic environment variable substitution is supported, where ${FOO} is replaced by the string value of the environment variable of the same name. Also $FOO may appear as separate word on the command line in which case the variable is replaced by its value split at whitespaces. Note that the first argument (i.e. the binary to execute) may not be a variable, and must be a literal and absolute path name." Hmm, as I read your bug report, this is actually not what happens? *** Bug 663358 has been marked as a duplicate of this bug. *** I don't know why ${OPTIONS} should behave differently than $OPTIONS, because it's misleading. These variables looks like shell variables and from shell's pov both are interpreted the same way. Anyway, ${var} does not work too, because $var is interpreted as "-a -b" and ${var} as "\"-a -b\"" For ${FOO} functionality from man page, "$FOO" should be used and ${FOO} should work the same way as $FOO. $FOO is split with this assignment (not valid in shell) FOO=-a -b but not with this one FOO="-a -b" So it seems the problem is that systemd doesn't remove the quotes. Oh, indeed. I guess that should be simple to fix. Fixed now in git. |