streaming-website/serve.sh

23 lines
260 B
Bash
Raw Normal View History

2016-06-20 20:41:47 +00:00
#!/bin/sh
2021-04-04 10:43:39 +00:00
php_bin=""
2016-08-19 09:23:42 +00:00
port=8000
2021-04-04 10:43:39 +00:00
for try_bin in php7 php
2021-04-04 10:43:39 +00:00
do
php_bin=$(command -v $try_bin)
if [ -n "$php_bin" ]
2021-04-04 10:43:39 +00:00
then
break
fi
done
echo "Using PHP: $php_bin"
if [ -n "$1" ]
then
port=$1
fi
$php_bin -S localhost:$port -d short_open_tag=true index.php