Live data from Hacker News

A Starter Kit for Emergency Websites

mxb.dev

91–100 of 113 posts

Re: A Starter Kit for Emergency Websites

#91
post #23

What we did for tacticalvote.co.uk: 1. A static site generator, with markdown as the source input in Github 2. Data from Google Sheets 3. A bash job on a cron that would poll both for changes... if changes exist, re-publish the site or data and purge Cloudflare cache using their API 4. Configure Cloudflare via Page Rule to Cache Everything Even with a very high change rate and hundreds of thousands of visitors a day…

That sounds like a really nice approach. Out of interest what does that sort of traffic end up costing on the Cloudflare side - presumably that's where the cost ends up here?

Re: A Starter Kit for Emergency Websites

#92
post #23

What we did for tacticalvote.co.uk: 1. A static site generator, with markdown as the source input in Github 2. Data from Google Sheets 3. A bash job on a cron that would poll both for changes... if changes exist, re-publish the site or data and purge Cloudflare cache using their API 4. Configure Cloudflare via Page Rule to Cache Everything Even with a very high change rate and hundreds of thousands of visitors a day…

That sounds like a really nice approach. Out of interest what does that sort of traffic end up costing on the Cloudflare side - presumably that's where the cost ends up here?

It's a free account on Cloudflare.

Cloudflare do not charge for bandwidth... and so it's free.

This whole setup is $5 per month for the hosting, though we do use Github personal and that is $7.00 per month.

Re: A Starter Kit for Emergency Websites

#93
post #89

Earlier quoted context omitted.

Most web hosts and VPS solutions have unlimited traffic no?

No, most VPS start charging extra if you exceed their limits.

I get between 5 and 20 TB out per month, depending on host. That’s a loooot of 14kb page loads.

Re: A Starter Kit for Emergency Websites

#94

The simplest solution is to make a static website of your dynamic one using wget, and then publish that. I did this e.g. for Wordpress sites, works really well and is very reliable. The process can be triggered via a cron script or manually (I wrote a small Wordpress plugin for it). No special hardware, infrastructure or cloud services required. Just make sure all resources are reachable via a link (so wget can find…

Any chance you could share the script / wget settings you are using for wordpress?

Re: A Starter Kit for Emergency Websites

#95
post #77

Or just create a static HTML file and put the damn thing in a S3 bucket behind a cloudfront proxy. That site is virtually guaranteed to never go down even with insane amoumts of traffic (plus it's edge optimized so a user in new delhi won't be sending requests to your server in los angeles) edit: The whole setup takes like less than 2 minutes and can be even automated it with 2 aws cli commands.

That's pretty close to what Netlify is doing behind the scenes, isn't it? Why would configuring it yourself be better? Netlify has way more experience at that than most people.

Netlify likes to go down unless you are paying for the high tier. Also they charge for bandwidth after 100gb's ($20 for another 100gb's which is basically stealing money compare to how much a 100gbs is worth).

I would not recommend Netlify if you have other options.

Re: A Starter Kit for Emergency Websites

#96
post #17

I mean, call me crazy, if this is for an emergency, wouldn't it make more sense to provide a small archive with the source files in it, no third party at all. requires an unarchiver, and a text editor.

Provide how? From a webserver? Back to square 1.

Web seeded torrent?

Re: A Starter Kit for Emergency Websites

#98
post #77

Earlier quoted context omitted.

That's pretty close to what Netlify is doing behind the scenes, isn't it? Why would configuring it yourself be better? Netlify has way more experience at that than most people.

Netlify likes to go down unless you are paying for the high tier. Also they charge for bandwidth after 100gb's ($20 for another 100gb's which is basically stealing money compare to how much a 100gbs is worth). I would not recommend Netlify if you have other options.

I have more than 30 sites on the free tier of Netlify and I've never known it to be down.

Re: A Starter Kit for Emergency Websites

#99

The simplest solution is to make a static website of your dynamic one using wget, and then publish that. I did this e.g. for Wordpress sites, works really well and is very reliable. The process can be triggered via a cron script or manually (I wrote a small Wordpress plugin for it). No special hardware, infrastructure or cloud services required. Just make sure all resources are reachable via a link (so wget can find…

Any chance you could share the script / wget settings you are using for wordpress?

Normally you can just use

> wget --mirror --convert-links --adjust-extension --page-requisites --no-parent http://example.org

This should make a full copy of your website (source: https://www.guyrutenberg.com/2014/05/02/make-offline-mirror-...).

I don't have the source of the Wordpress plugin anymore unfortunately.

Post reply on HN