convert init.d to systemd, how to determine which python is installed
Toshio Kuratomi
a.badger at gmail.com
Thu Nov 3 16:32:30 UTC 2011
On Thu, Nov 03, 2011 at 03:17:47PM +0000, "Jóhann B. Guðmundsson" wrote:
>
> Just out of curiosity are there any guidelines forbidding creating a
> symbolic link to that file from /usr/sbin
>
> So instead of having a unit file that looks like this...
>
> [Unit]
> Description=HekaFS an Clustered File System Server
> Requires=glusterd.service
> After=network.target glusterd.service
>
> [Service]
> Type=oneshot
> ExecStart=/usr/lib/python2.7/site-packages/hekafsd.py -l
> /var/log/hekafs/hekafsd -p /run/hekafsd.pid
> RemainAfterExit=yes
>
> [Install]
> WantedBy=multi-user.target
>
> You would have a unit file like this...
>
> [Unit]
> Description=HekaFS an Clustered File System Server
> Requires=glusterd.service
> After=network.target glusterd.service
>
> [Service]
> Type=oneshot
> ExecStart=/usr/sbin/hekafsd -l /var/log/hekafs/hekafsd -p /run/hekafsd.pid
> RemainAfterExit=yes
>
> [Install]
> WantedBy=multi-user.target
>
> And just move the link upon update/upgrade pointing to the new version?
>
That looks doable. It's similar to the wrapper concept but less overhead
for this simple case.
-Toshio
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: not available
Url : http://lists.fedoraproject.org/pipermail/devel/attachments/20111103/5ea12b08/attachment.bin
More information about the devel
mailing list