Live data from Hacker News

Wordpress on AWS: smooth and pain free

cloudonaut.io

81–90 of 124 posts

Re: Wordpress on AWS: smooth and pain free

#81
post #4

And this cloud setup is going to cost probably for few hundreds of dollars a month. Has anybody working towards serverless version of wp?

> Has anybody working towards serverless version of wp?

I'm curious on what a "serverless version of wordpress" consists of, please enlighten us on the technical details of a serverless wordpress, sincerely. And how would you have a "serverless shopping card" too ? I'm really curious about the how it. If you're talking about a static blog generator then it already exists (Hugo,...) is this what you call serverless ?

Re: Wordpress on AWS: smooth and pain free

#82

This guide is spot on for WordPress on AWS. The persistent and shared EFS volume was the missing piece for running WordPress without frustrating patches. And CloudFormation is the AWS best practice. Convox has a few serious WordPress installs. The only difference is that it uses ECS so those EC2 instances can be utilized for more apps. Also you can hack on the WordPress site locally with Docker via 'convox start' htt…

I tried EFS and it seemed very slow for the wordpress site I tried to host. I didn't think EFS was meant for hosting a webserver but mainly for large files?

Re: Wordpress on AWS: smooth and pain free

#83
post #76
post #75

This is one way to do it, though I can't recommend it as the best way. The first step is building your WordPress site correctly, and for me, that starts with using trellis ( https://roots.io/trellis ) and bedrock ( https://roots.io/bedrock ). He's partially correct about S3 for media and uploads, but you want to take it one step further and use Imgix for actual image (jpeg/png) delivery because it'll do all of the tr…

And avoid caching plugins. Most of them are garbage.

You really can't use WP without some form of caching (be it a plugin or proxy).

I do wonder how much energy is wasted from poorly optimised websites & systems?

Re: Wordpress on AWS: smooth and pain free

#84
post #4

And this cloud setup is going to cost probably for few hundreds of dollars a month. Has anybody working towards serverless version of wp?

> Has anybody working towards serverless version of wp? I'm curious on what a "serverless version of wordpress" consists of, please enlighten us on the technical details of a serverless wordpress, sincerely. And how would you have a "serverless shopping card" too ? I'm really curious about the how it. If you're talking about a static blog generator then it already exists (Hugo,...) is this what you call serverless ?

I read "serverless" in this context to mean a statically generated site, yes. I also infer that dynamic content like authentication, shopping carts, forms, etc would be third party solutions via Ajax and CORS.

I built a service [1] for this latter part (authentication, CORS sql database, and static file hosting). The pieces one could use to build anything for a statically generated site. Adoption has been... non existent up to now.

[1] https://www.lite-engine.com

Re: Wordpress on AWS: smooth and pain free

#85
I do similar for my personal website on Azure, they have a Wordpress plugin that maps the upload folder to use a blob storage instance. It's a bit dated and doesn't support things like custom domains using https (for the blob.) Something I hope they address (it's 2016 guys.) I don't know if this Amazon solution does the same thing or not. However currently I have to use my Blob's CNAME domain to serve assets over https. I use Cloudflare to manage my certs instead of Cloudfront like they do here.

I'm looking for a solution for my agency to put sites onto hosted instances like AWS or Azure, but my hesitance is that they aren't managed solutions and I'm afraid of getting hacked. Does anyone have any insight on how secure these solutions can be? My Azure instance has been running for years without problems, but that's my gamble with my one site and not hundreds of customer sites. I use CloudFlare's page rules to add extra security and caching and have WordFence just in case.

I'd love some insight into how I could scale a solution like this to be hundreds of sites on cloud instances while maintaining security. Perhaps they should all be separate? Would my personal solution be good for my company's clients? Managed solutions like WPEngine are just outrageously expensive for some of the sites we have that only get a handful of traffic (Azure offers Wordpress on Azure websites.)

Re: Wordpress on AWS: smooth and pain free

#86
I have to disagree with the author. I have setup Wordpress using OpsWorks and it is a much better way to do this especially considering all of the stack can be auto managed via Chef. Updates are handled automatically and if you get a surge of traffic, autoscale kicks in.

The only issue is getting the plugins to auto update on all of the servers, which I am fairly certain you can do with Chef or WordPress just handles it.

Re: Wordpress on AWS: smooth and pain free

#87

Yes, you can do this. But, what about a staging environment? How do you keep data and code in sync between environments? My company runs a lot of wordpress instances, and we've wound up shipping most of them to Pantheon. (pantheon.io) Not only does it take care of environment issues, but it gives you redis and implements caching as a service. As the post says, wordpress fights AWS a bit. We leave it to the people who…

Requiring the $100/mo plan and charging an additional $30/mo for HTTPS seems.. dated. It makes me wonder if they're behind the times with other things too.

Re: Wordpress on AWS: smooth and pain free

#88

I do similar for my personal website on Azure, they have a Wordpress plugin that maps the upload folder to use a blob storage instance. It's a bit dated and doesn't support things like custom domains using https (for the blob.) Something I hope they address (it's 2016 guys.) I don't know if this Amazon solution does the same thing or not. However currently I have to use my Blob's CNAME domain to serve assets over htt…

I'm assuming you're on Debian or Ubuntu. You can set up automatic security updates on Apt, and if you have a firewall you're halfway there. Then I would make sure each website has its own user, group, and www-user and using file permissions, make it so each virtualhost doesn't have access to others' files.

If you wanna be extra safe you can have each site on its own vps. Although what's nice about keeping a bunch on 1 big vps is that you get to save a lot of time managing it as it can take a while to propagate changes across many VPS and if they all have different setups it can get confusing.

To do 1 site per vps properly, you should have fleet management going like Ansible or Puppet so that you can maintain them all easily. That way all the code is hosted on a build server, and individual environments get built for each site.

Re: Wordpress on AWS: smooth and pain free

#89
post #76

Earlier quoted context omitted.

And avoid caching plugins. Most of them are garbage.

You really can't use WP without some form of caching (be it a plugin or proxy). I do wonder how much energy is wasted from poorly optimised websites & systems?

The root post of this thread is pointing out that you should always run WP behind a CDN like CloudFlare. That will handle all of the caching that you need. If you're running a truly static site, then you're going to have very few actual hits to your server.

Re: Wordpress on AWS: smooth and pain free

#90
post #18

Why is anyone running WordPress anymore.? So many better options.100s if not 1,000s. The fact that you need elaborate guides to host it one of the most common hosting providers is yet another example. It's junk. Time to move on. Edit: and the down votes are why this piece of garbage lives on. Please stop trying to hide how awful WordPress is. We all know it's terrible. Just because you work on it for a living doesn't…

Please don't comment like this on Hacker News. The quality of WordPress is not relevant to this article, and even if it were we would ask you to say something substantive rather than simply calling it junk. The guidelines also ask you not to complain about downvotes, so please review them here: https://news.ycombinator.com/newsguidelines.html.
Post reply on HN