AWS EC2实例,它指向亚马逊的Linux AMI测试页而不是WP网站亚马逊、而不是、实例、测试

2023-09-11 09:03:39 作者:Archer(久遇)

我决定玩的AWS EC2并成立了一个字preSS网站上的64位Linux实例。

I decided to play around with AWS EC2 and set up a Wordpress site on a 64-bit Linux Instance.

我已经完全建立了LAMP的情况下,安装了Word preSS,并指出我的域名服务器。当我尝试访问该网站 http://latesttech.tips 我得到了亚马逊的Linux AMI测试页,并以唯一的方式访问Word preSS是访问 http://latesttech.tips/lttwp 。

I have fully set up the instance with LAMP, installed Wordpress and pointed my domain to the server. When I try to access the site http://latesttech.tips I get the Amazon Linux AMI Test Page and the only way to access Wordpress is to visit http://latesttech.tips/lttwp.

我怎样才能有主域指向lttwp目录中自动所以这并不一定要通过URL做了什么?

How can I have the primary domain to point to the "lttwp" directory automatically so this doesn't have to be done via the URL?

我是相当新的开发的世界,抬头如何解决,也没有找到任何东西。

I'm fairly new in the dev world and looked up how to fix, but couldn't find anything.

在此先感谢!

推荐答案

您可以编辑你的Apache配置文件重定向到您的lttwp文件夹。

You can edit your apache config file to redirect to your lttwp folder.

通常的configs为Apache在的/ etc / httpd的/ conf目录的/ etc / apache2的/ conf目录查找对目录的变量。您将需要修改该路径2-3处的配置为它工作。查找的DocumentRoot 目录变量。

Usually the configs for apache are in /etc/httpd/conf or /etc/apache2/conf Look for the directory variable. You will need to edit that path at 2-3 place in the config for it to work. Look for the documentroot and directory variables.

您可以在这里找到更多信息: http://httpd.apache.org/docs /2.2/configuring.html

You can find more info here : http://httpd.apache.org/docs/2.2/configuring.html

完成后,重新启动Apache服务器,因此,它需要新的配置:须藤服务的httpd重新启动

Once done, restart the apache server so that it takes new config: sudo service httpd restart