Merge branch 'master' of https://github.com/alanbjohnston/CubeSatSim
commit
0ffcd637d3
@ -0,0 +1,12 @@
|
|||||||
|
sudo mv custom.target /etc/systemd/system/custom.target
|
||||||
|
|
||||||
|
sudo mv new.service /etc/systemd/system/custom.target.wants/new.service
|
||||||
|
|
||||||
|
sudo systemctl list-units --type target --all
|
||||||
|
|
||||||
|
sudo systemctl isolate custom.target
|
||||||
|
|
||||||
|
sudo ln -sf /etc/systemd/system/custom.target /etc/systemd/system/default.target
|
||||||
|
|
||||||
|
sudo reboot now
|
||||||
|
|
||||||
@ -0,0 +1,5 @@
|
|||||||
|
[Unit]
|
||||||
|
Description=Custom Target
|
||||||
|
Requires=multi-user.target
|
||||||
|
After=multi-user.target
|
||||||
|
AllowIsolate=yes
|
||||||
@ -0,0 +1,10 @@
|
|||||||
|
[Unit]
|
||||||
|
Description=My last command
|
||||||
|
After=multi-user.target
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=simple
|
||||||
|
ExecStart=/home/pi/CubeSatSim/demo.sh > /home/pi/CubeSatSim/log.txt 2>&1
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=custom.target
|
||||||
Loading…
Reference in new issue