News for hackers. Stuff that matters.
Re:GitHub Stale Bots – A False Economy by ljm on Monday January 18, 2021 @09:24AM (#25822050)
It turns out that building a site in plain HTML, without fancy tools, isn't nearly as difficult as using stuff like gatsby once you get down to it.

Hell, just throw in some PHP if you want dynamic bits and pieces. Your fancy netlify/cloudflare/vercel setup may not like it but your infinitely cheaper shared host/VPS provider will.

If you still wanted static output, you could probably serve it locally and then let wget crawl it for you.

Re:GitHub Stale Bots – A False Economy by icebraining on Monday January 18, 2021 @01:25PM (#25824813)
> infinitely cheaper

It's actually the opposite. Static site hosting is so much easier to optimize, that it costs just few cents a month, if anything at all (I never went beyond Netlify's free plan).

Re:GitHub Stale Bots – A False Economy by ljm on Tuesday January 19, 2021 @06:14PM (#25840276)
That's the cost of hosting the end result. How much of your precious time did you spend building your site in a way to make 'static site hosting' (i.e. a file server behind a CDN) work? Did you put time into some CI workflow on Github to precompile the site and push it to Netlify? Did you mess around with Netlify itself to build what you want?

I can do exactly the same with a cheap VPS running apache and PHP and a deploy is little more than an SCP or FTP upload away. I don't have to worry about a build pipeline at all.

I'm not aiming this at you, but in general I'd love to see how newer engineers would tackle things like deployment if they couldn't rely on some SaaS offering.

Or are we talking about static sites that are static because they do all the server side stuff on the browser, and you're pulling down things like react and graphql to render a blog post?

Re:GitHub Stale Bots – A False Economy by icebraining on Tuesday January 19, 2021 @07:46PM (#25841158)
Nah, no CI workflow, I generate locally. Creating the site was just

  pip install pelican; git init . ; pelican-quickstart; vim pelicanconf.py  # to set the theme
Then to publish:

  pelican . && git add -A && git commit -m "post title" && git push
(I have a shortcut for this, of course)

But I think you overestimate the time to "setup the CI workflow" actually takes. It's just a text file where you put the commands above, so it can run on the server instead of your machine. There's no black magic to it.

> I don't have to worry about a build pipeline at all.

Of course you do; it's just that your build pipeline runs every time someone accesses your site.

> I'm not aiming this at you, but in general I'd love to see how newer engineers would tackle things like deployment if they couldn't rely on some SaaS offering.

I've done that too. I created a bare git repo on the server, with a post-receive hook that checkouts "master" and runs the static site generator. Then I had Nginx serve the directory.

Re:GitHub Stale Bots – A False Economy by madeofpalk on Tuesday January 19, 2021 @06:34AM (#25832420)
> I never went beyond Netlify's free plan

There you go. Go beyond Netlify's free plan and it can get pretty expensive.

Re:GitHub Stale Bots – A False Economy by icebraining on Tuesday January 19, 2021 @06:03PM (#25840152)
Not really, you can just easily switch to another solution, like B2+Cloudflare, which costs pennies.
Re:GitHub Stale Bots – A False Economy by madeofpalk on Monday January 18, 2021 @11:37AM (#25823469)
> If you still wanted static output, you could probably serve it locally and then let wget crawl it for you.

Here's the complexity part that tools try to solve.

Re:GitHub Stale Bots – A False Economy by john-shaffer on Monday January 18, 2021 @02:19PM (#25825409)
There are decoupled tools like https://statically.io/ to do this. One can have the straightforward builds of GP and still have good static site generation.
Re:GitHub Stale Bots – A False Economy by madeofpalk on Tuesday January 19, 2021 @06:02AM (#25832183)
cool, we've just made something more complicated than netlify or whatever.

Looks like a great tool for migrating an existing dynamic site into a more static workflow, but it's not exactly the workflow I was replying to.