Mercurial > code > home > repos > light9
annotate bin/homepage @ 2028:feb9a47980bb
chmod a+x bin/*
author | drewp@bigasterisk.com |
---|---|
date | Tue, 05 Apr 2022 23:15:01 -0700 |
parents | e30493d458f9 |
children | 224c4a1625d7 |
rev | line source |
---|---|
1212 | 1 #!/bin/zsh |
2 | |
3 CONF=/tmp/light9_nginx.conf | |
4 ROOT=`dirname $0`/.. | |
5 ROOT=${ROOT:a} | |
6 | |
1521 | 7 bin/homepageConfig > /tmp/light9_nginx_routes.conf && \ |
1212 | 8 cat > $CONF <<EOF |
9 worker_processes 1; | |
10 | |
11 daemon off; | |
12 error_log /tmp/light9_homepage.err; | |
13 pid /dev/null; | |
14 | |
15 events { | |
16 worker_connections 1024; | |
17 } | |
18 | |
19 http { | |
20 include $ROOT/light9/web/mime.types; | |
21 | |
22 server { | |
1215 | 23 access_log off; |
1706
e30493d458f9
more npm setup. n3 upgraded but code is not, yet
drewp@bigasterisk.com
parents:
1521
diff
changeset
|
24 autoindex on; |
1212 | 25 |
1215 | 26 include "/tmp/light9_nginx_routes.conf"; |
1212 | 27 |
28 location / { | |
29 root $ROOT/light9/web; | |
30 } | |
31 | |
1706
e30493d458f9
more npm setup. n3 upgraded but code is not, yet
drewp@bigasterisk.com
parents:
1521
diff
changeset
|
32 location /node_modules { |
e30493d458f9
more npm setup. n3 upgraded but code is not, yet
drewp@bigasterisk.com
parents:
1521
diff
changeset
|
33 root $ROOT/; |
e30493d458f9
more npm setup. n3 upgraded but code is not, yet
drewp@bigasterisk.com
parents:
1521
diff
changeset
|
34 } |
e30493d458f9
more npm setup. n3 upgraded but code is not, yet
drewp@bigasterisk.com
parents:
1521
diff
changeset
|
35 |
1212 | 36 } |
37 } | |
38 EOF | |
1225
70f42f9d6e04
simplify homepageConfig. get homepage port from rdf. get rdfdb port from rdf
Drew Perttula <drewp@bigasterisk.com>
parents:
1215
diff
changeset
|
39 head -1 /tmp/light9_nginx_routes.conf |
1411 | 40 exec /usr/sbin/nginx -c $CONF |