[systemd-bugs] [Bug 72249] New: Ability to set StandardInput to a file

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Mon Dec 2 13:16:42 PST 2013


https://bugs.freedesktop.org/show_bug.cgi?id=72249

          Priority: medium
            Bug ID: 72249
          Assignee: systemd-bugs at lists.freedesktop.org
           Summary: Ability to set StandardInput to a file
        QA Contact: systemd-bugs at lists.freedesktop.org
          Severity: enhancement
    Classification: Unclassified
                OS: All
          Reporter: jharvell at dogpad.net
          Hardware: All
            Status: NEW
           Version: unspecified
         Component: general
           Product: systemd

I was making an service for iptables, running iptables-restore and discovered
that the StandardInput option does not allow me to set the standard input of an
exec to a regular file.  This was a little surpirising since there are so many
other process properties you can control as documented in the systemd.exec man
page.

For iptables-restore, I worked around this limitation by creating the following
wrapper script:

{code}
#!/bin/bash
in="$1"
shift
exec $* < "$in"
{code}

It would be nice to avoid the overhead of starting up a shell just to redirect
the standard input.

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/systemd-bugs/attachments/20131202/3d4035bb/attachment.html>


More information about the systemd-bugs mailing list