jeebus ... futzing around with nginx again so that absolute path in conf is not necessary
This commit is contained in:
22
docroot/Makefile
Normal file
22
docroot/Makefile
Normal file
@@ -0,0 +1,22 @@
|
||||
|
||||
ROOT ?= $(PWD)
|
||||
HTTP_PORT ?= 49448
|
||||
PHP_FCGI_PORT ?= 49449
|
||||
|
||||
|
||||
serve: nginx.conf
|
||||
nginx -p $(ROOT)/ -c $(ROOT)/$<
|
||||
|
||||
|
||||
serve-php:
|
||||
php-cgi -b 127.0.0.1:$(PHP_FCGI_PORT)
|
||||
|
||||
|
||||
nginx.conf: nginx.conf.in
|
||||
cat $< | \
|
||||
sed -e 's@__ROOT__@$(ROOT)@g' \
|
||||
-e 's@__HTTP_PORT__@$(HTTP_PORT)@g' \
|
||||
-e 's@__PHP_FCGI_PORT__@$(PHP_FCGI_PORT)@g' > $@
|
||||
|
||||
|
||||
.PHONY: serve
|
Reference in New Issue
Block a user