script/ethercat.service.in
author Edouard Tisserant <edouard.tisserant@gmail.com>
Fri, 05 Oct 2018 23:47:07 +0200
branchstable-1.5
changeset 2722 5e5bec5ee9c1
parent 2539 d2d43d2e7f31
permissions -rw-r--r--
rtdmnet.c : Fixed rt/nrt invertion for both sendmsg and recvmsg... m(
2192
1c7c546ac08c Added first systemd support.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
     1
#
2539
d2d43d2e7f31 Added notes about systemd dependencies.
Florian Pose <fp@igh-essen.com>
parents: 2377
diff changeset
     2
# EtherCAT master kernel modules
2192
1c7c546ac08c Added first systemd support.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
     3
#
1c7c546ac08c Added first systemd support.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
     4
1c7c546ac08c Added first systemd support.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
     5
[Unit]
1c7c546ac08c Added first systemd support.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
     6
Description=EtherCAT Master Kernel Modules
1c7c546ac08c Added first systemd support.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
     7
2539
d2d43d2e7f31 Added notes about systemd dependencies.
Florian Pose <fp@igh-essen.com>
parents: 2377
diff changeset
     8
#
d2d43d2e7f31 Added notes about systemd dependencies.
Florian Pose <fp@igh-essen.com>
parents: 2377
diff changeset
     9
# Uncomment this, if the generic Ethernet driver is used. It assures, that the
d2d43d2e7f31 Added notes about systemd dependencies.
Florian Pose <fp@igh-essen.com>
parents: 2377
diff changeset
    10
# network interfaces are configured, before the master starts.
d2d43d2e7f31 Added notes about systemd dependencies.
Florian Pose <fp@igh-essen.com>
parents: 2377
diff changeset
    11
#
d2d43d2e7f31 Added notes about systemd dependencies.
Florian Pose <fp@igh-essen.com>
parents: 2377
diff changeset
    12
#Requires=network.service # Stop master, if network is stopped
d2d43d2e7f31 Added notes about systemd dependencies.
Florian Pose <fp@igh-essen.com>
parents: 2377
diff changeset
    13
#After=network.service # Start master, after network is ready
d2d43d2e7f31 Added notes about systemd dependencies.
Florian Pose <fp@igh-essen.com>
parents: 2377
diff changeset
    14
d2d43d2e7f31 Added notes about systemd dependencies.
Florian Pose <fp@igh-essen.com>
parents: 2377
diff changeset
    15
#
d2d43d2e7f31 Added notes about systemd dependencies.
Florian Pose <fp@igh-essen.com>
parents: 2377
diff changeset
    16
# Uncomment this, if a native Ethernet driver is used. It assures, that the
d2d43d2e7f31 Added notes about systemd dependencies.
Florian Pose <fp@igh-essen.com>
parents: 2377
diff changeset
    17
# network interfaces are configured, after the Ethernet drivers have been
d2d43d2e7f31 Added notes about systemd dependencies.
Florian Pose <fp@igh-essen.com>
parents: 2377
diff changeset
    18
# replaced. Otherwise, the networking configuration tools could be confused.
d2d43d2e7f31 Added notes about systemd dependencies.
Florian Pose <fp@igh-essen.com>
parents: 2377
diff changeset
    19
#
d2d43d2e7f31 Added notes about systemd dependencies.
Florian Pose <fp@igh-essen.com>
parents: 2377
diff changeset
    20
#Before=network.service
d2d43d2e7f31 Added notes about systemd dependencies.
Florian Pose <fp@igh-essen.com>
parents: 2377
diff changeset
    21
2192
1c7c546ac08c Added first systemd support.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
    22
[Service]
1c7c546ac08c Added first systemd support.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
    23
Type=oneshot
1c7c546ac08c Added first systemd support.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
    24
RemainAfterExit=yes
1c7c546ac08c Added first systemd support.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
    25
ExecStart=@prefix@/sbin/ethercatctl start
1c7c546ac08c Added first systemd support.
Florian Pose <fp@igh-essen.com>
parents:
diff changeset
    26
ExecStop=@prefix@/sbin/ethercatctl stop
2377
aa0f6f939cb3 Install ethercat service to multi-user target by default.
Florian Pose <fp@igh-essen.com>
parents: 2192
diff changeset
    27
aa0f6f939cb3 Install ethercat service to multi-user target by default.
Florian Pose <fp@igh-essen.com>
parents: 2192
diff changeset
    28
[Install]
aa0f6f939cb3 Install ethercat service to multi-user target by default.
Florian Pose <fp@igh-essen.com>
parents: 2192
diff changeset
    29
WantedBy=multi-user.target