如何在使用 CentOS 的 Amazon Web 服务主机上设置 Magento? [英] How to set up Magento on a Amazon Web Service Hosting with CentOS?
问题描述
我必须在 Amazon Web Service 上设置一个开发/测试平台.所以有人告诉我,安装它",但我不知道该怎么做.我非常习惯 1&1、OVH 和其他托管公司,我通过 FileZilla 上传我的数据,但在这里似乎完全不同.我错了吗?
I have to set up a dev/test platform on the Amazon Web Service. So I was told, "install it" but I have no clue how to do that. I'm very used to 1&1, OVH and other hosting companies on which I upload my data through FileZilla but here it seems to be completely different. Am I wrong?
我读到我需要安装 centOS 才能与服务器通信,对吧?没有其他办法吗?FileZilla?
I read that I would need to install centOS to communicate with the server, right? is there no other way to do so? FileZilla?
顺便问一下,我如何在 AWS 上设置 Magento?我找到了一些关于它的文档:
And By the Way, how do I set up Magento on AWS? I found some documentation about it :
http://loadstorm.com/2009/magento-setup-amazon-associates-web-service
http://www.zetaprints.com/magentohelp/category/overview/
http://www.greengecko.co.nz/magento_on_amazon_ec2
但每次,我似乎都错过了第一行中的某些内容,即 VERY FIRST 步骤.有人可以启发我,因为我认为我在这个过程的起点错过了一些东西,而且我显然不明白它的工作方式.
But each time, it seems that I missed something in the first lines, the VERY FIRST step. Could someone enlightene me please because I think I missed something at the starting point of this process and I clearly don't understand the way it works.
我下载了 elasticFirefox 扩展和 S3 管理器,但它们对理解没有太大帮助.在我读过的每个文档中,这个人都是从我无法到达的地方开始的......
I downloaded both elasticFirefox extension and S3 organizer, but they are not very helpful for the understanding. In each of the docs I have read, the guy starts from a point I can't reach ..
PS:我已经开始使用 Magento 开发网站,所以它是关于转移这个版本的 Magento 而不是安装新版本.. 除非它要复杂得多..
PS: I've started developing the website with Magento so it is about transfering this version of Magento instead of installing a new one .. except if it's much much more complicated ..
任何帮助或完整文档将不胜感激:)
Any Help or full documentation would be appreciated :)
感谢您的帮助!
推荐答案
我做了一些非常相似的事情(在 rackspase 上使用 CentOS 5.5) - 请按照以下步骤操作.所有以--"开头的行都应视为备注.在开始转移"Magento 之前,您应该安装 PHP、httpd 和 MySql:
I did something very much alike (using CentOS 5.5 on rackspase) - follow the steps below. all the lines that start with "--" should be treated as remarks. Before you start "transferring" Magento you should install PHP, httpd and MySql:
-- MySql
-- MySql
yum install mysql-server
-- httpd
-- httpd
yum install httpd
-- 在 iptables 中打开 80 端口
-- open port 80 in iptables
vi /etc/sysconfig/iptables
--添加一行:
-- add a line:
-A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp --dport 80 -j ACCEPT
--配置httpd.conf(启用.htaccess)
-- configure httpd.conf (enable the use of .htaccess)
vi /etc/httpd/conf/httpd.conf
更改<从AllowOverride None"到AllowOverride All"的目录/var/www/html >"
change the line under "< Directory "/var/www/html >" from "AllowOverride None" to "AllowOverride All"
-- 安装 php 5
-- install php 5
rpm -ivh http://repo.webtatic.com/yum/centos/5/`uname -i`/webtatic-release-5-1.noarch.rpm
yum --enablerepo=webtatic install php
yum --enablerepo=webtatic install php-mysql
-- 转到/var/www/html
-- go to /var/www/html
cd /var/www/html
-- 并复制 Magento 的所有内容
--然后清理缓存(如果有):
-- and copy there all the content of Magento
--then clean cache if any:
rm -rf /var/www/html/<your app>/var/cache/*
-- 你必须创建一个模式:
-- you have to create a schema:
mysql
mysql> create database [your schema name];
mysql> grant all privileges on [your schema name].* to [your username]@localhost identified by '[your password]';
-- 在您的计算机上创建 sql 转储:
-- create sql dump on your computer:
mysqldump [your schema name] > [your schema name].sql
--并在centos上导入
-- and import it on centos
mysql [your schema name] < [your schema name].sql;
--确保用户名/密码配置正确:
--Make sure that the username/password are configured properly:
vi <your app>/app/etc/local.xml
-- 以 [您的用户] 身份登录数据库:
-- Login the DB as [your user]:
mysql -u [your user] –p
-- 找到配置为 localhost 的条目(因为您是在计算机上开发的)并将其更改为安装服务器的 IP(例如 1.1.1.1):
-- Locate the entry that is configured to localhost (since you developed it on your computer) and change it to the installation-server’s IP (say 1.1.1.1):
select path, value from [your schema name].core_config_data where path like '%base_url%';
update [your schema name].core_config_data set value = 'http:/<your domain>/<your app>/' where path like '%base_url%';
-- 现在重启所有服务
-- now restart all the services
service iptables restart
service mysqld restart
service httpd restart
-- 疑难解答
-- Troubleshooting
In order to print error to screen follow these steps:
cd /var/www/html/<your app>/errors
cp local.xml.sample local.xml
这篇关于如何在使用 CentOS 的 Amazon Web 服务主机上设置 Magento?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!