What I did was put my wiki behind a nginx LB with this config. This says READ requests (GET, HEAD) are permitted by anyone, but POST and other requests require user authentication.
server { listen 80; access_log /var/log/nginx/tiddlywiki.access.log combined; location / { root /opt/html; index index.html index.htm; } location /wiki/ { limit_except GET HEAD { auth_basic 'Restricted'; auth_basic_user_file /etc/nginx/auth/tiddlywiki; } proxy_pass http://127.0.0.1:8888/; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; } } On Wednesday, September 20, 2017 at 2:28:25 PM UTC-4, Kevin Kleinfelter wrote: > > It would be real handy if *I* could edit my node.js TW, share links to it, > and block the sharers from updating. I understand that I can export the > site as HTML and publish that HTML file, but I've got lots of images. > 99.9% of the time, I only need to say to someone, "Here's a permalink. > Read this one story for your answer." > > The use-case is that I have lots of reference material, my job involves > solving people's technical problems, and I'd like to send them a pointer to > my canned solution. > > I'm wondering how I might set things up so that when accessed via > 127.0.0.1, full functionality is available, but when accessed via other IP, > it is read-only. > > If I were running this on Linux, I'd use umask and file permissions and > run a second node.js as the nobody user. I'm running node.js as a Windows > service, and it is in an Active Directory environment, where creating a new > user-ID takes an act of congress. > > I *could* just set up a daily file copy, replicate my whole TW to a second > folder, and let the "public" trash the disposable copy. I'd prefer not to > go that route. > > Any clever ideas for a read-only instance using the same data? > -- You received this message because you are subscribed to the Google Groups "TiddlyWiki" group. To unsubscribe from this group and stop receiving emails from it, send an email to tiddlywiki+unsubscr...@googlegroups.com. To post to this group, send email to tiddlywiki@googlegroups.com. Visit this group at https://groups.google.com/group/tiddlywiki. To view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/45bafa76-4d98-40f5-bd28-11d816d55fe3%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.