Crazy musings - Serverless Plone

Sounds like a GSoC 2018 project idea?

sure! why not? 2018 is also the year we're going to conquest Mars:

@pigeonflight if the usecase is a hosting provider then serverless doesn't make economic sense most likely. Unless the traffic is extremely bursty. Once you have many clients on a shared platform the average traffic is fairly constant. Even starting and stopping whole servers might not be worth your while if the sites target many timezones. Also given AWS gives you significant discounts for year long servers which would make a stable setup cheaper I would guess.

The one possibly compelling usecase I can see would be as a way for people to host their own small sites in a very cheap manner. But then again, with AWS free tier you can do it now for free.... only just. and if you traffic bursts it will stop serving. Serverless is basically only cheap when most of the time you aren't using it. Then you need to switch. At least for now.

I think a better use of our time would be working on getting one click installs into as many free tier hosting providers as we can, not just AWS and heroku. If we did it via something like docker we might be able to have an single install that automatically grows as the server or servers are resized.
Since no one is out there providing SaaS plone, or cheap plone hosting (without significant ops knowledge), if we can come up with an alternative it could make plone more popular.

It kills me when people go on about how Plone isn't easy to host cheap. On a $10/month Linode I have 20-30 sites. I can spin up a new site in a minute...add it to a domain in a few more (nginx config and restart, cloudflare for DNS and ssl). Automating it wouldn't be particularly hard. The billing would be harder but not much I don't think.

Growth. I don't really know that if $1/month hosting on an AWS serverless platform is actually what is needed to make plone popular but lets say hypothetically it is. Hypothetically, a bunch of people didn't recommend plone, or looked at it and rejected it because they found LAMP hosting for drupal/WP or whatever cheaper and that was their only blocker...
In this hypothetical scenario, would it be worth putting that effort in to save someone $4/month?
IMO yes, because it would make us all more money in the long run.

you are saying it's not hard to offer shared hosting of plone as a service or it's not hard for someone to host their own plone site?

I would agree that its not so hard for someone to host plone as a service since we can assume that anyone doing that is reasonably technical. The more TTW capabilities we add to plone, the more that becomes compelling. Part of the reason that currently doesn't work is because it is currently limited what you can do TTW and all the documentation specifies non TTW things, so you end up needing to deploy hacks into the core such as jbot and that doesn't work for shared plone hosting.

If you are saying its easy for a first time programmer with no experience of linux to host a plone site themselves? I don't think so. Just look at how much buildout issues we've had with GSOC developers and thats not even hosting.
I think we are getting closer however. And I think with more and more hosters providing direct docker support, I think this could provide a nice cross platform way to provide a easy hosting experience.
But again we need more work on TTW in the core (like rapido) and more documentation, such that its obvious how to make a complex site without touching buildout, zcml, setup.py or the cli.

Firstly... just reiterating that this is all about early morning musing :slight_smile:

I can confirm that I've seen this play out. Someone very comfortable with PHP and CPanel based hosting is rendered near helpless when presented with the task of deploying another stack (Python WSGI, Rails...., Tomcat) to a DigitalOcean type platform. With persistence and some hand-holding they can get it but it is, to many, a non-trivial task.

@pigeonflight Since 2017 I've seen the rise and rise of strapi simply because it fit into the heroku free tier without needing a credit card. This meant people on fiverr could build you a full functioning CMS site using heroku, strapi, gatsby and netlify that worked for most cases as long as you weren't editing for hours and hours on end each month. Simply because the CMS slept most of the time and netflfy did all the public requests. Being all JS also helps make this a popular choice of course.

It's true having a popular CMS doesn't help most companies involved in plone in the short term and actually hurts them. But in the long term it would via the long tail effect.

The heroku free tier is gone now. and there would be a lot of reasons Plone wouldn't be the popular choice for low end websites om free tier but I still wonder if the following is possible

  • strip down plone rest api backend such that start up times are under 20s so it could start from cold quick enough on lambda. lambda free tier is 1M requests and 512mb storage. It stays loaded for 30-40min so after the initial cold start editing would be normal I think.
  • aws RDS postgres is free db.t2.micro, db.t3.micro, and db.t4g.micro and 20gb storage. Enough for a small site.
  • turn volto into a static site generator on netlify by crawling the site after each save or publish and hosting the static html on netflify. For small sites a simple crawl would be enough but this could be optimised to just grab changed content.
  • AWS requires a credit card for free tier but perhaps other services don't?
  • Either have no search and form submissions. or keep them but accept the big delay or going over the free tier limits. It would be better to replace search and forms with other lighter solutions.

So in theory this would be a free Plone 6 site that lets you edit the content with volto as long as you are ok with slow login when you start editing. Would this make it attractive for small integrators who don't want to deal with hosting for their clients?

1 Like

This is interesting, for the right project it could make sense but there's definitely a threshold that you need to cross in order to justify Plone.

For many customers I've found that deploying to Netlify CMS makes sense, this is what I'm doing for smaller projects. The next tier after that is Webflow and Webflow hosting.

Plone makes sense when the problem space includes custom workflows, groups and user accounts. Also in spaces where there is a need to have more "ownership" of your hosting infrastructure.

I think the hidden assumption here is which cost you are talking about when you talk about "justify".
If we assume the above is possible and hosting is free then is the main cost you are thinking of then time to make a custom theme? or complexity of UI making it overwhelming for users?
Certainly using gatsby would speed up theme development but then you lose the nice editing experience. But as strapi/gatsby popularity shows, maybe editing experience is just not that important for small sites?

This is what a free hosting experience looks like - How I Hosted my Strapi Headless CMS driver website for Free.
It's not about it being a single click experience like squarespace. But it does make it attractive to smaller integrators and inhouse devops.

I'm guessing Nick CMS with volto would be a lot faster to start than normal Plone - GitHub - robgietema/nick. So far seems not to be lacking much. Be interesting to know what you lose by switching from plone to nick?

But you still have the cost of theming if you want to use volto....

The cost of theming is a big deal on smaller projects. In general, having to bring in developer to get a task done, adds cost. In the end, it's a tradeoff. When Plone is needed you just have to invest in the cost of theming. I've found that smaller projects don't mind a less slick backend. But you don't need to sacrifice the backend either, for just a little more, they can use Webflow... I wrote an article about that a couple years ago, see below...

This quarter I will be able to make the comparison as I'll be on a project, working with a React dev, to build a theme for Volto. Perhaps I can try it out on Nick during development.