在Elastic Beanstalk上部署WordPress? [英] Deploying WordPress on Elastic Beanstalk?

查看:91
本文介绍了在Elastic Beanstalk上部署WordPress?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

假设我在Wordpress中创建了一个站点,该站点在Elastic Beanstalk上运行.现在,在正在运行的应用程序中,我将创建帖子/页面,上传图像等.也就是说,数据库中的某些数据,视频,文件和记录将添加到正在运行的应用程序中.

Suppose I create a site in Wordpress, which is running on Elastic Beanstalk. Now, on the running app I will create posts /pages, upload images, etc. That is, some data, videos, files and records in a database will be added to the running application.

3个问题:

  1. 如果WordPress在Elastic Beanstalk上运行,并且有多个Amazon EC2实例实际在运行我的WordPress安装,那么这些文件会自动传播到所有正在运行的实例吗?如果启动了新的EC2实例(例如,以处理增加的负载),也会发生这种情况吗?

  1. If WordPress is running on Elastic Beanstalk with multiple Amazon EC2 instances actually running my WordPress install, then will those files propagate automatically to all running instances? And will this also happen, if a new EC2 instance is fired up - for example, to handle increased load?

从我在AWS控制台中看到的内容,我可以部署不同版本的应用程序-但是按照上述方案,如果部署新版本,则不会丢失直接上传到正在运行的应用程序中的所有文件(即文件和数据库记录)?如何保留这些并同时部署我的应用程序的新版本?

From what I see in AWS console, I can deploy different versions of an app-- but as per scenario above, if I deploy a new version, wont I lose all the files uploaded directly into running app (i.e. files and database records)? How do I keep those and at the same time deploy a new version of my app?

WordPress团队不断发布升级.我可以通过网络界面直接升级正在运行的WordPress安装吗?还是我必须先升级本地版本的WordPress,然后将新版本的应用程序上载到Beanstalk?如果必须先升级本地版本然后再上传,那么我又回到了第1点,即用户直接对正在运行的应用的旧版本进行了更改.如何保存这些更改?

The WordPress team keeps issuing upgrades. Can I directly upgrade my running WordPress install, through the web interface? Or do I have to first upgrade my local version of WordPress, and then upload the new version of the app to Beanstalk? If I have to upgrade my local version and then upload, then again I am back to point 1, i.e. changes made by users directly to the older version of running app. How do I preserve those changes?

推荐答案

好的,我在这个特定问题上进行了很多研究,这就是我学到的东西-

OK I researched a lot on this particular issue, and this is what I learned--

(1)如果wordpress用户上载了一些文件,则他的文件将仅被上载到当时实际服务于其请求的虚拟机.例如,如果当前wordpress站点是云部署的并且正在使用5个虚拟机,那么现在当用户发出请求时,他将被定向到一个虚拟机-那个时候负载最小的虚拟机...他的上传仅存储在该虚拟机上服务器.当前的平台即服务解决方案(例如Amazon Elastic Beanstalk和App Fog)无法将更改传播到所有正在运行的实例.要么(传播对所有服务器的更改),要么在所有正在运行的实例中使用一个公共存储,这是解决此问题的仅有的两种解决方案. (例如,通用存储将是使用网络附加存储(NAS)的所有5个正在运行的虚拟机...)

(1) If a wordpress user uploads some files, then his files will be uploaded only to the virtual machine that is actually serving his request at that time. Eg if currently the wordpress site is cloud-deployed and is using 5 virtual machines, now when user makes request he is directed to one virtual machine-- the one with the lowest load at that point... His uploads are stored only on that server. Current Platform-as-a-service solutions (like Amazon Elastic Beanstalk and App Fog) do not have the ability to propagate the changes to all the running instances. Either that (propagate changes to all servers) or use a common storage by all running instances-- these are the only 2 solutions to this problem. (Eg of common storage would be all 5 running virtual machines using Network-Attached-Storage (NAS)... )

(2)例如,参考用户当前可用的平台,例如Amazon Elastic Beanstalk和App Fog,即使用户直接对运行的应用程序进行了更改,这些平台也依赖于本地版本的代码(管理员最初将其部署到云中)-并且无法通过用户对正在运行的应用所做的更改来更新本地代码版本(在管理员的PC上)-因此这些更改即文件丢失-同样,用户对数据库的更改也正在运行应用程序也会丢失-除非管理员为其本地应用程序(部署到云)使用完全相同的数据库

(2) With ref to platforms available currently like Amazon Elastic Beanstalk and App Fog, for example, even if user made changes directly to running app- these platforms rely on the local version of code (which the admin deployed initially to cloud)- and there is no way to update the local version of code (on admin's PC) with the changes made by a user to running app-- hence these changes viz, files are lost-- Similarly, changes in database by user to running app are also lost-- unless the admin is using exactly the same database for his local app (that he deployed to cloud)

(3)必须先对正在运行的应用程序进行任何更改,然后在管理员的PC上对本地应用程序进行更改,然后将其推送到云中.

(3) Any changes to running apps first have to be made to the local app on admin's PC and then pushed to cloud.

我正在致力于解决所有这些问题的Cloud PaaS-可以对正在运行的应用程序进行更新,对正在运行的应用程序进行的代码更改也可以在用户可访问的代码存储库中进行更新...概念验证已准备就绪,希望它会和我希望的一样好:)-目前唯一存在的网站(anyacloudpanel.com)-设计工作正在进行:)

I am working on a Cloud PaaS that addresses all these concerns-- viz updates can be made to running apps, code changes made to running app are also updated in code repository accessible by user...The Proof of concept is ready, hopefully it will be as good as I hope it should be :) -- currently the only thing that is actually there is the website (anyacloudpanel.com) -- design work is going on :)

如果有某些规定我不应该提及我的网站(Anya Cloud Panel),那么很抱歉-请随时从我的答案中编辑和删除我的网站URL:)

If there is some rule that I should not mention my website( Anya Cloud Panel) -- then I am sorry -- pls feel free to edit and remove my website URL from my answer :)

谢谢, 阿文.

这篇关于在Elastic Beanstalk上部署WordPress?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆