修改TUN模式环境适配服务
This commit is contained in:
@@ -1,6 +1,9 @@
|
|||||||
|
|
||||||
TFE_DEVICE_DATA_INCOMING=ens1f1
|
TFE_DEVICE_DATA_INCOMING=tun_kni
|
||||||
TFE_LOCAL_MAC_DATA_INCOMING=fe:65:b7:00:00:01
|
TFE_LOCAL_MAC_DATA_INCOMING=fe:65:b7:00:00:01
|
||||||
TFE_PEER_MAC_DATA_INCOMING=aa:bb:cc:dd:ee:ff
|
TFE_PEER_MAC_DATA_INCOMING=aa:bb:cc:dd:ee:ff
|
||||||
TFE_LOCAL_IP_DATA_INCOMING=172.16.241.2
|
TFE_LOCAL_IP_DATA_INCOMING=172.16.241.2
|
||||||
TFE_PEER_IP_DATA_INCOMING=172.16.241.1
|
TFE_PEER_IP_DATA_INCOMING=172.16.241.1
|
||||||
|
TFE_WATCHDOG_DEVICE=enp2s0
|
||||||
|
TFE_WATCHDOG_IP=192.168.100.1
|
||||||
|
|
||||||
|
|||||||
@@ -13,6 +13,7 @@ ExecStart=/bin/true
|
|||||||
ExecStop=/bin/true
|
ExecStop=/bin/true
|
||||||
|
|
||||||
# start
|
# start
|
||||||
|
ExecStartPost=/usr/sbin/ifconfig ${TFE_WATCHDOG_DEVICE} ${TFE_WATCHDOG_IP}
|
||||||
ExecStartPost=/usr/sbin/ip tuntap add dev ${TFE_DEVICE_DATA_INCOMING} mode tap
|
ExecStartPost=/usr/sbin/ip tuntap add dev ${TFE_DEVICE_DATA_INCOMING} mode tap
|
||||||
ExecStartPost=/usr/sbin/ifconfig ${TFE_DEVICE_DATA_INCOMING} up
|
ExecStartPost=/usr/sbin/ifconfig ${TFE_DEVICE_DATA_INCOMING} up
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
[Unit]
|
[Unit]
|
||||||
Description=Tango Frontend Engine - Running Environment Setup
|
Description=Tango Frontend Engine - Running Environment Setup
|
||||||
Before=tfe.service
|
Before=tsgkni.service
|
||||||
Wants=network-online.target
|
Wants=network-online.target
|
||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
|
|||||||
16
script/service/tsgkni.service
Normal file
16
script/service/tsgkni.service
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
[Unit]
|
||||||
|
Description=tsg kni module
|
||||||
|
Requires=tfe-env.service
|
||||||
|
After=tfe-env.service
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
WorkingDirectory=/home/tsg/kni
|
||||||
|
#ExecStart=/home/tsg/kni/kni_service_scipt start
|
||||||
|
ExecStart=/home/tsg/kni/sapp
|
||||||
|
#ExecStop=/home/tsg/kni/kni_service_scipt stop
|
||||||
|
#Type=forking
|
||||||
|
Restart=always
|
||||||
|
RestartSec=5s
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
||||||
14
script/service/tsgtfe.service
Normal file
14
script/service/tsgtfe.service
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
[Unit]
|
||||||
|
Description=tsg tfe module
|
||||||
|
Requires=tsgkni.service
|
||||||
|
After=tsgkni.service
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
WorkingDirectory=/home/tsg/tfe/
|
||||||
|
ExecStart=/home/tsg/tfe/bin/tfe
|
||||||
|
ExecStop=/bin/kill -9 $MAINPID
|
||||||
|
Restart=always
|
||||||
|
RestartSec=5s
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
||||||
Reference in New Issue
Block a user