Compare commits
190 Commits
c0b54ad843
...
ccm-svg-sp
| Author | SHA1 | Date | |
|---|---|---|---|
| 9d9fa13340 | |||
| 36953062d0 | |||
| 5a99a01eed | |||
| 09bee9627c | |||
| 96153b9a74 | |||
| 22ab464f5d | |||
| b54853559f | |||
| af8e222045 | |||
| 7f07c94c82 | |||
| 94df5140f8 | |||
| df6cf1f75c | |||
| 0d63f87e39 | |||
| 3bb5536820 | |||
| 340b30c8dc | |||
| 4f9db0a940 | |||
| c783394d01 | |||
| a13a03e031 | |||
| 3194245309 | |||
| 6074b36c99 | |||
| d278da060b | |||
| 418fd716b0 | |||
| c708dadde0 | |||
| 70f958606d | |||
| 424cb0f150 | |||
| d89909e7bf | |||
| 93937df1fd | |||
| 6d7214dd46 | |||
| 66a044cd2a | |||
| 52e7fd9f9b | |||
| fae1fd255f | |||
| 93157f17dd | |||
| 965ed86ed6 | |||
| 478c90e398 | |||
| 89cf20e35a | |||
| d2a8758fb8 | |||
| 8198fc7b63 | |||
| 0b6f7a55c0 | |||
| de0052aa0a | |||
| 6f580b2b77 | |||
| 5bb861c376 | |||
| ccc6dc1335 | |||
| 853728624a | |||
| 435eb0b128 | |||
| 7408005ed2 | |||
| aaff3571af | |||
| 176fd98cb5 | |||
| e1cfff39f0 | |||
| 55f6328d3f | |||
| b509ba12ea | |||
| 4b692194ae | |||
| 112c100057 | |||
| 20bcd976a8 | |||
| 2e17234daf | |||
| ac9684f4cf | |||
| c6ed409915 | |||
| 00f2243f03 | |||
| 616c8184d0 | |||
| d779f802a6 | |||
| 12d9d8ae95 | |||
| b68f63b379 | |||
| 0fad07d341 | |||
| f0ddd4e13a | |||
| bbb6cd2c07 | |||
| 965287bcf4 | |||
| e027291ec8 | |||
| ca9ceebd64 | |||
| 50a851eb2f | |||
| c250275b1d | |||
| c8d17b7d46 | |||
| 0e4da0fc67 | |||
| da2b1d9a6f | |||
| 4fd9688d53 | |||
| 69a0a1dcdd | |||
| c8b1d9c8f6 | |||
| ed83435218 | |||
| 3fa1e8f722 | |||
| da1bebe4f2 | |||
| b81f0a8565 | |||
| b9884ba077 | |||
| d17d0f0a08 | |||
| 625cae288c | |||
| 5c5c76f9a1 | |||
| e9a86c532e | |||
| 2c89910ee8 | |||
| 1de687b3f1 | |||
| d9ab0fa1fd | |||
| b3f6d79c01 | |||
| df2eb64ed5 | |||
| 2f2a82c46f | |||
| 607486d308 | |||
| d6dddc25db | |||
| a0f580da95 | |||
| f3db10ac68 | |||
| 406c5d1357 | |||
| 8db51f8870 | |||
| 607eaa187e | |||
| 0868c953a3 | |||
| d45575db7c | |||
| b9b744d10f | |||
| c4c0fdd86d | |||
| 65c4c69f21 | |||
| c4c8667d4f | |||
| 08c71c05e6 | |||
| 6723e5f5af | |||
| 109d1aa6fe | |||
| 2d72c7f83e | |||
| e1e2c479af | |||
| e8cc4e5241 | |||
| 4903812ca1 | |||
| 1ab48b58c3 | |||
| 38c01d27bf | |||
| 790c267957 | |||
| bb193630b9 | |||
| 46167340be | |||
| b836b1f92b | |||
| b8df14625c | |||
| c9b7c62365 | |||
| d75c8f1b0f | |||
| d13392fef6 | |||
| 722e8172ab | |||
| d732fe0bf1 | |||
| 63e9c45490 | |||
| be61acb030 | |||
| 803402beef | |||
| 1fd87f8351 | |||
| b6bc696823 | |||
| d65e5c2b34 | |||
| f7984595cc | |||
| 32c1d0e56d | |||
| d0369ca229 | |||
| 19a7a26f1b | |||
| 962e1e4094 | |||
| 1a7d6233d8 | |||
| 60ac7f137b | |||
| 5b594d369b | |||
| 5868ef2b24 | |||
| 2c2226d09f | |||
| 1c2f35c87b | |||
| a6fde9e567 | |||
| eb9c805786 | |||
| 8f963ab98c | |||
| 5089a30a3b | |||
| e7f098dedf | |||
| 273ed43a51 | |||
| f6974d43f4 | |||
| 95c45ac7c6 | |||
| 6d7669ac10 | |||
| 5d02620b55 | |||
| a8f9cce90e | |||
| 50a20982a4 | |||
| 1f782f75aa | |||
| f9a191048a | |||
| fc5a1155dd | |||
| f3a702cce0 | |||
| 598ecde00e | |||
| fcbae33d51 | |||
| 7b63f0524c | |||
| 5a5b4e9272 | |||
| 8705b5779d | |||
| 8b89673b6f | |||
| 29588b36d4 | |||
| 7ad55c07ae | |||
| c3bd622841 | |||
| 2b6fadab29 | |||
| 4a44a21395 | |||
| 660bfba1b9 | |||
| 0282a0b721 | |||
| a0c804823c | |||
| 235ea57e81 | |||
| 9e8987fcc0 | |||
| 0b841d8873 | |||
| 9730ff85fb | |||
| bf807f9e29 | |||
| 264cb1dc81 | |||
| 5b3710ac4a | |||
| 138a2122e0 | |||
| b1fd38196e | |||
| 60836c9028 | |||
| 43f5fccebf | |||
| c33c9ec4bc | |||
| b358c2c0c5 | |||
| 58952cfa88 | |||
| d4e1bf5b9e | |||
| 6418c10415 | |||
| d2163d060b | |||
| 1baf76d901 | |||
| 88241ad705 | |||
| 37f683e9a5 | |||
| b735a6e124 | |||
| 5c74ee4cbe |
62
Dockerfile
62
Dockerfile
@@ -1,15 +1,64 @@
|
|||||||
FROM openresty/openresty:bookworm-buildpack
|
FROM buildpack-deps:trixie
|
||||||
|
|
||||||
WORKDIR /opt/app
|
ARG version=3.8.2.1
|
||||||
|
|
||||||
ARG version=3.7.0.1
|
|
||||||
ARG pkgname=pandoc-$version-1-amd64.deb
|
ARG pkgname=pandoc-$version-1-amd64.deb
|
||||||
ARG pkgurl=https://github.com/jgm/pandoc/releases/download/$version/$pkgname
|
ARG pkgurl=https://github.com/jgm/pandoc/releases/download/$version/$pkgname
|
||||||
|
|
||||||
|
ARG RESTY_DEB_FLAVOR=""
|
||||||
|
ARG RESTY_DEB_VERSION="=1.27.1.2-1~bookworm1"
|
||||||
|
ARG RESTY_LUAROCKS_VERSION="3.12.2"
|
||||||
|
|
||||||
RUN apt-get update && apt-get install -y \
|
RUN apt-get update && apt-get install -y \
|
||||||
python3-pygments lua-inotify wget && \
|
python3-pygments lua-inotify wget && \
|
||||||
wget -q -O $pkgname $pkgurl && dpkg -i $pkgname && rm $pkgname
|
wget -q -O $pkgname $pkgurl && dpkg -i $pkgname && rm $pkgname
|
||||||
|
|
||||||
|
RUN wget -qO - https://openresty.org/package/pubkey.gpg | gpg --dearmor > /etc/apt/trusted.gpg.d/openresty-keyring.gpg \
|
||||||
|
&& chown root:root /etc/apt/trusted.gpg.d/openresty-keyring.gpg \
|
||||||
|
&& chmod ugo+r /etc/apt/trusted.gpg.d/openresty-keyring.gpg \
|
||||||
|
&& chmod go-w /etc/apt/trusted.gpg.d/openresty-keyring.gpg \
|
||||||
|
&& echo "\nTypes: deb\nURIs: https://openresty.org/package/debian\nSuites: bookworm\nComponents: openresty\nEnabled: yes\nSigned-By: /etc/apt/trusted.gpg.d/openresty-keyring.gpg" >> /etc/apt/sources.list.d/debian.sources \
|
||||||
|
&& DEBIAN_FRONTEND=noninteractive apt-get update \
|
||||||
|
&& DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
|
||||||
|
openresty${RESTY_DEB_FLAVOR}${RESTY_DEB_VERSION} \
|
||||||
|
openresty-resty${RESTY_DEB_FLAVOR}${RESTY_DEB_VERSION} \
|
||||||
|
openresty-opm${RESTY_DEB_FLAVOR}${RESTY_DEB_VERSION} \
|
||||||
|
openresty-openssl3${RESTY_DEB_FLAVOR}-dev \
|
||||||
|
openresty-pcre2${RESTY_DEB_FLAVOR}-dev \
|
||||||
|
openresty-zlib${RESTY_DEB_FLAVOR}-dev \
|
||||||
|
&& mkdir -p /var/run/openresty \
|
||||||
|
&& ln -sf /dev/stdout /usr/local/openresty${RESTY_DEB_FLAVOR}/nginx/logs/access.log \
|
||||||
|
&& ln -sf /dev/stderr /usr/local/openresty${RESTY_DEB_FLAVOR}/nginx/logs/error.log
|
||||||
|
|
||||||
|
# Install LuaRocks
|
||||||
|
RUN curl -fSL https://luarocks.github.io/luarocks/releases/luarocks-${RESTY_LUAROCKS_VERSION}.tar.gz -o luarocks-${RESTY_LUAROCKS_VERSION}.tar.gz \
|
||||||
|
&& tar xzf luarocks-${RESTY_LUAROCKS_VERSION}.tar.gz \
|
||||||
|
&& cd luarocks-${RESTY_LUAROCKS_VERSION} \
|
||||||
|
&& mkdir -p /usr/local/openresty/luajit \
|
||||||
|
&& ./configure \
|
||||||
|
--prefix=/usr/local/openresty/luajit \
|
||||||
|
--with-lua=/usr/local/openresty/luajit \
|
||||||
|
--with-lua-include=/usr/local/openresty/luajit/include/luajit-2.1 \
|
||||||
|
&& make build \
|
||||||
|
&& make install \
|
||||||
|
&& cd /tmp \
|
||||||
|
&& rm -rf luarocks-${RESTY_LUAROCKS_VERSION} luarocks-${RESTY_LUAROCKS_VERSION}.tar.gz
|
||||||
|
|
||||||
|
# Add additional binaries into PATH for convenience
|
||||||
|
ENV PATH="$PATH:/usr/local/openresty${RESTY_DEB_FLAVOR}/luajit/bin:/usr/local/openresty${RESTY_DEB_FLAVOR}/nginx/sbin:/usr/local/openresty${RESTY_DEB_FLAVOR}/bin"
|
||||||
|
|
||||||
|
# Add LuaRocks paths
|
||||||
|
# If OpenResty changes, these may need updating:
|
||||||
|
# /usr/local/openresty/bin/resty -e 'print(package.path)'
|
||||||
|
# /usr/local/openresty/bin/resty -e 'print(package.cpath)'
|
||||||
|
ENV LUA_PATH="/usr/local/openresty/site/lualib/?.ljbc;/usr/local/openresty/site/lualib/?/init.ljbc;/usr/local/openresty/lualib/?.ljbc;/usr/local/openresty/lualib/?/init.ljbc;/usr/local/openresty/site/lualib/?.lua;/usr/local/openresty/site/lualib/?/init.lua;/usr/local/openresty/lualib/?.lua;/usr/local/openresty/lualib/?/init.lua;./?.lua;/usr/local/openresty/luajit/share/luajit-2.1/?.lua;/usr/local/share/lua/5.1/?.lua;/usr/local/share/lua/5.1/?/init.lua;/usr/local/openresty/luajit/share/lua/5.1/?.lua;/usr/local/openresty/luajit/share/lua/5.1/?/init.lua"
|
||||||
|
ENV LUA_CPATH="/usr/local/openresty/site/lualib/?.so;/usr/local/openresty/lualib/?.so;./?.so;/usr/local/lib/lua/5.1/?.so;/usr/local/openresty/luajit/lib/lua/5.1/?.so;/usr/local/lib/lua/5.1/loadall.so;/usr/local/openresty/luajit/lib/lua/5.1/?.so"
|
||||||
|
|
||||||
|
WORKDIR /opt/app
|
||||||
|
|
||||||
|
# Copy nginx configuration files
|
||||||
|
COPY nginx.conf /usr/local/openresty${RESTY_DEB_FLAVOR}/nginx/conf/nginx.conf
|
||||||
|
COPY nginx.vh.default.conf /etc/nginx/conf.d/default.conf
|
||||||
|
|
||||||
RUN luarocks install sitegen
|
RUN luarocks install sitegen
|
||||||
|
|
||||||
# needed for sitegen watcher
|
# needed for sitegen watcher
|
||||||
@@ -35,3 +84,8 @@ RUN mkdir -p /var/www/certs/webdevcat.me \
|
|||||||
-addext "subjectAltName=DNS:webdevcat.me,DNS:git.webdevcat.me,DNS:apps.webdevcat.me"
|
-addext "subjectAltName=DNS:webdevcat.me,DNS:git.webdevcat.me,DNS:apps.webdevcat.me"
|
||||||
|
|
||||||
CMD ["sh", "-c", "openresty -p `pwd` -g 'daemon off;'"]
|
CMD ["sh", "-c", "openresty -p `pwd` -g 'daemon off;'"]
|
||||||
|
|
||||||
|
# Use SIGQUIT instead of default SIGTERM to cleanly drain requests
|
||||||
|
# See https://github.com/openresty/docker-openresty/blob/master/README.md#tips--pitfalls
|
||||||
|
STOPSIGNAL SIGQUIT
|
||||||
|
|
||||||
|
|||||||
3
Makefile
3
Makefile
@@ -5,6 +5,9 @@ serve:
|
|||||||
docker run --rm -it --init -v $(PWD):/opt/app -p 8080:80 $(image) \
|
docker run --rm -it --init -v $(PWD):/opt/app -p 8080:80 $(image) \
|
||||||
sh -c "openresty -p /opt/app -g 'daemon off;' -c conf/dev.nginx.conf"
|
sh -c "openresty -p /opt/app -g 'daemon off;' -c conf/dev.nginx.conf"
|
||||||
|
|
||||||
|
shell:
|
||||||
|
docker run --rm -it --init -v $(PWD):/opt/app -p 8080:80 $(image) bash
|
||||||
|
|
||||||
build:
|
build:
|
||||||
$(if $(file), $(docker-run) sitegen build $(file), $(docker-run) sitegen)
|
$(if $(file), $(docker-run) sitegen build $(file), $(docker-run) sitegen)
|
||||||
|
|
||||||
|
|||||||
57
README.md
57
README.md
@@ -1,23 +1,26 @@
|
|||||||
## requirements
|
## requirements
|
||||||
|
|
||||||
`pandoc` utility must be installed
|
* Docker
|
||||||
|
|
||||||
- Debian Bookworm:
|
## up and running
|
||||||
|
|
||||||
$ apt-get update && apt-get install -y pandoc
|
### build container image
|
||||||
|
|
||||||
## start default openresty
|
|
||||||
|
|
||||||
1. Run `docker run --rm -it --init -w /opt -v $PWD:/opt -p 80:80 openresty/openresty:1.27.1.2-0-bookworm-buildpack`
|
|
||||||
2. Visit `localhost` in web browser.
|
|
||||||
|
|
||||||
## start a custom site
|
|
||||||
|
|
||||||
### build docker image
|
|
||||||
|
|
||||||
$ make image-build
|
$ make image-build
|
||||||
|
|
||||||
### rebuild an existing docker image
|
### build site
|
||||||
|
|
||||||
|
$ make build
|
||||||
|
|
||||||
|
### start dev server
|
||||||
|
|
||||||
|
$ make serve
|
||||||
|
|
||||||
|
Visit `localhost:8080` in web browser
|
||||||
|
|
||||||
|
## getting around
|
||||||
|
|
||||||
|
### rebuild the container image
|
||||||
|
|
||||||
$ make image-rm image-build
|
$ make image-rm image-build
|
||||||
|
|
||||||
@@ -27,9 +30,11 @@
|
|||||||
|
|
||||||
### add an index page
|
### add an index page
|
||||||
|
|
||||||
|
#### create the file
|
||||||
|
|
||||||
$ docker run --rm -w /opt/app -v $PWD:/opt/app miti.sh sitegen page /opt/app index
|
$ docker run --rm -w /opt/app -v $PWD:/opt/app miti.sh sitegen page /opt/app index
|
||||||
|
|
||||||
### add to `site.moon`
|
#### add to `site.moon`
|
||||||
|
|
||||||
add "index.md"
|
add "index.md"
|
||||||
|
|
||||||
@@ -52,19 +57,13 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
### build site
|
|
||||||
|
|
||||||
$ make build
|
|
||||||
|
|
||||||
### build a single file
|
### build a single file
|
||||||
|
|
||||||
$ make build file=index.html
|
$ make build file=index.html
|
||||||
|
|
||||||
### start dev server
|
### start a shell
|
||||||
|
|
||||||
$ make serve
|
$ make shell
|
||||||
|
|
||||||
Visit `localhost:8080` in web browser
|
|
||||||
|
|
||||||
### start watcher
|
### start watcher
|
||||||
|
|
||||||
@@ -90,6 +89,13 @@ example:
|
|||||||
|
|
||||||
$ make deploy
|
$ make deploy
|
||||||
|
|
||||||
|
### renew server TSL certs
|
||||||
|
|
||||||
|
SSH into server admin account and run:
|
||||||
|
|
||||||
|
$ cd www
|
||||||
|
$ dehydrated --config config -c
|
||||||
|
|
||||||
## gotchas
|
## gotchas
|
||||||
|
|
||||||
### What is error `cosmo failed: [string "..."]:62: cannot resume dead coroutine`?
|
### What is error `cosmo failed: [string "..."]:62: cannot resume dead coroutine`?
|
||||||
@@ -113,3 +119,10 @@ Delete your `.sitegen_cache` file.
|
|||||||
* use sitecache with pandoc renderer
|
* use sitecache with pandoc renderer
|
||||||
* draft documents
|
* draft documents
|
||||||
* treesitter highlighting for moonscript
|
* treesitter highlighting for moonscript
|
||||||
|
|
||||||
|
## todo
|
||||||
|
|
||||||
|
* destroy a target ship by shooting them with the cannon
|
||||||
|
* make corners not bouncy (leave them bouncy for now?)
|
||||||
|
* wall entities
|
||||||
|
* ship-ship collision
|
||||||
|
|||||||
1627
html/images/space.svg
Normal file
1627
html/images/space.svg
Normal file
File diff suppressed because it is too large
Load Diff
|
After Width: | Height: | Size: 53 KiB |
117
nginx.conf
Normal file
117
nginx.conf
Normal file
@@ -0,0 +1,117 @@
|
|||||||
|
|
||||||
|
#user nobody;
|
||||||
|
worker_processes 1;
|
||||||
|
|
||||||
|
#error_log logs/error.log;
|
||||||
|
#error_log logs/error.log notice;
|
||||||
|
#error_log logs/error.log info;
|
||||||
|
|
||||||
|
#pid logs/nginx.pid;
|
||||||
|
|
||||||
|
|
||||||
|
events {
|
||||||
|
worker_connections 1024;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
http {
|
||||||
|
include mime.types;
|
||||||
|
default_type application/octet-stream;
|
||||||
|
|
||||||
|
#log_format main '$remote_addr - $remote_user [$time_local] "$request" '
|
||||||
|
# '$status $body_bytes_sent "$http_referer" '
|
||||||
|
# '"$http_user_agent" "$http_x_forwarded_for"';
|
||||||
|
|
||||||
|
#access_log logs/access.log main;
|
||||||
|
|
||||||
|
sendfile on;
|
||||||
|
#tcp_nopush on;
|
||||||
|
|
||||||
|
#keepalive_timeout 0;
|
||||||
|
keepalive_timeout 65;
|
||||||
|
|
||||||
|
#gzip on;
|
||||||
|
|
||||||
|
server {
|
||||||
|
listen 80;
|
||||||
|
server_name localhost;
|
||||||
|
|
||||||
|
#charset koi8-r;
|
||||||
|
|
||||||
|
#access_log logs/host.access.log main;
|
||||||
|
|
||||||
|
location / {
|
||||||
|
root html;
|
||||||
|
index index.html index.htm;
|
||||||
|
}
|
||||||
|
|
||||||
|
#error_page 404 /404.html;
|
||||||
|
|
||||||
|
# redirect server error pages to the static page /50x.html
|
||||||
|
#
|
||||||
|
error_page 500 502 503 504 /50x.html;
|
||||||
|
location = /50x.html {
|
||||||
|
root html;
|
||||||
|
}
|
||||||
|
|
||||||
|
# proxy the PHP scripts to Apache listening on 127.0.0.1:80
|
||||||
|
#
|
||||||
|
#location ~ \.php$ {
|
||||||
|
# proxy_pass http://127.0.0.1;
|
||||||
|
#}
|
||||||
|
|
||||||
|
# pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
|
||||||
|
#
|
||||||
|
#location ~ \.php$ {
|
||||||
|
# root html;
|
||||||
|
# fastcgi_pass 127.0.0.1:9000;
|
||||||
|
# fastcgi_index index.php;
|
||||||
|
# fastcgi_param SCRIPT_FILENAME /scripts$fastcgi_script_name;
|
||||||
|
# include fastcgi_params;
|
||||||
|
#}
|
||||||
|
|
||||||
|
# deny access to .htaccess files, if Apache's document root
|
||||||
|
# concurs with nginx's one
|
||||||
|
#
|
||||||
|
#location ~ /\.ht {
|
||||||
|
# deny all;
|
||||||
|
#}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
# another virtual host using mix of IP-, name-, and port-based configuration
|
||||||
|
#
|
||||||
|
#server {
|
||||||
|
# listen 8000;
|
||||||
|
# listen somename:8080;
|
||||||
|
# server_name somename alias another.alias;
|
||||||
|
|
||||||
|
# location / {
|
||||||
|
# root html;
|
||||||
|
# index index.html index.htm;
|
||||||
|
# }
|
||||||
|
#}
|
||||||
|
|
||||||
|
|
||||||
|
# HTTPS server
|
||||||
|
#
|
||||||
|
#server {
|
||||||
|
# listen 443 ssl;
|
||||||
|
# server_name localhost;
|
||||||
|
|
||||||
|
# ssl_certificate cert.pem;
|
||||||
|
# ssl_certificate_key cert.key;
|
||||||
|
|
||||||
|
# ssl_session_cache shared:SSL:1m;
|
||||||
|
# ssl_session_timeout 5m;
|
||||||
|
|
||||||
|
# ssl_ciphers HIGH:!aNULL:!MD5;
|
||||||
|
# ssl_prefer_server_ciphers on;
|
||||||
|
|
||||||
|
# location / {
|
||||||
|
# root html;
|
||||||
|
# index index.html index.htm;
|
||||||
|
# }
|
||||||
|
#}
|
||||||
|
|
||||||
|
}
|
||||||
58
nginx.vh.default.conf
Normal file
58
nginx.vh.default.conf
Normal file
@@ -0,0 +1,58 @@
|
|||||||
|
# nginx.vh.default.conf -- docker-openresty
|
||||||
|
#
|
||||||
|
# This file is installed to:
|
||||||
|
# `/etc/nginx/conf.d/default.conf`
|
||||||
|
#
|
||||||
|
# It tracks the `server` section of the upstream OpenResty's `nginx.conf`.
|
||||||
|
#
|
||||||
|
# This config (and any other configs in `etc/nginx/conf.d/`) is loaded by
|
||||||
|
# default by the `include` directive in `/usr/local/openresty/nginx/conf/nginx.conf`.
|
||||||
|
#
|
||||||
|
# See https://github.com/openresty/docker-openresty/blob/master/README.md#nginx-config-files
|
||||||
|
#
|
||||||
|
|
||||||
|
|
||||||
|
server {
|
||||||
|
listen 80;
|
||||||
|
server_name localhost;
|
||||||
|
|
||||||
|
#charset koi8-r;
|
||||||
|
#access_log /var/log/nginx/host.access.log main;
|
||||||
|
|
||||||
|
location / {
|
||||||
|
root /usr/local/openresty/nginx/html;
|
||||||
|
index index.html index.htm;
|
||||||
|
}
|
||||||
|
|
||||||
|
#error_page 404 /404.html;
|
||||||
|
|
||||||
|
# redirect server error pages to the static page /50x.html
|
||||||
|
#
|
||||||
|
error_page 500 502 503 504 /50x.html;
|
||||||
|
location = /50x.html {
|
||||||
|
root /usr/local/openresty/nginx/html;
|
||||||
|
}
|
||||||
|
|
||||||
|
# proxy the PHP scripts to Apache listening on 127.0.0.1:80
|
||||||
|
#
|
||||||
|
#location ~ \.php$ {
|
||||||
|
# proxy_pass http://127.0.0.1;
|
||||||
|
#}
|
||||||
|
|
||||||
|
# pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
|
||||||
|
#
|
||||||
|
#location ~ \.php$ {
|
||||||
|
# root /usr/local/openresty/nginx/html;
|
||||||
|
# fastcgi_pass 127.0.0.1:9000;
|
||||||
|
# fastcgi_index index.php;
|
||||||
|
# fastcgi_param SCRIPT_FILENAME /scripts$fastcgi_script_name;
|
||||||
|
# include fastcgi_params;
|
||||||
|
#}
|
||||||
|
|
||||||
|
# deny access to .htaccess files, if Apache's document root
|
||||||
|
# concurs with nginx's one
|
||||||
|
#
|
||||||
|
#location ~ /\.ht {
|
||||||
|
# deny all;
|
||||||
|
#}
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user