-
-
Save alexandreaquiles/ca9c5c9ba8da5ed59242 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
if pgrep mjpg_streamer > /dev/null | |
then | |
echo "mjpg_streamer already running" | |
else | |
LD_LIBRARY_PATH=/opt/mjpg-streamer/ /opt/mjpg-streamer/mjpg_streamer -i "input_raspicam.so -fps 15 -q 50 -x 640 -y 480 -vf -hf" -o "output_http.so -p 9000 -w /opt/mjpg-streamer/www" > /dev/null 2>&1& | |
echo "mjpg_streamer started" | |
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
if pgrep mjpg_streamer | |
then | |
kill $(pgrep mjpg_streamer) > /dev/null 2>&1 | |
echo "mjpg_streamer stopped" | |
else | |
echo "mjpg_streamer not running" | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment