Refer:
http://coenraets.org/blog/2012/01/setting-up-wordpress-on-amazon-ec2-in-5-minutes/
http://coenraets.org/blog/2012/01/setting-up-wordpress-on-amazon-ec2-in-5-minutes/
Step 1: Install the Apache Web Server
To install the Apache Web Server, type:
yum install httpd
yum install httpd
Start the Apache Web Server:
service httpd start
service httpd start
To test your Web Server, open a browser and access your web site: http://ec2-50-17-14-16.compute-1.amazonaws.com (Use your actual public DNS name). You should see a standard Amazon place holder page.
Step 2: Install PHP
To install PHP, type:
yum install php php-mysql
yum install php php-mysql
Restart the Apache Web Server:
service httpd restart
service httpd restart
Create a page to test your PHP installation:
cd /var/www/html
vi test.php
cd /var/www/html
vi test.php
Open a browser and access test.php to test your PHP installation: http://ec2-50-17-14-16.compute-1.amazonaws.com/test.php (Use your actual public DNS name).
Step 3: Install MySQL
To install MySQL, type:
yum install mysql-server
yum install mysql-server
Start MySQL:
service mysqld start
service mysqld start
Create your “blog” database:
mysqladmin -uroot create blog
mysqladmin -uroot create blog
Secure your database:
mysql_secure_Installation
mysql_secure_Installation
Answer the wizard questions as follows:
Step 4: Install WordPress
To install WordPress, type:
cd /var/www/html
wget http://wordpress.org/latest.tar.gz
tar -xzvf latest.tar.gzcd
cd /var/www/html
wget http://wordpress.org/latest.tar.gz
tar -xzvf latest.tar.gzcd
This will uncompress WordPress in its own “wordpress” directory. I like having WordPress in a separate directory, but would rather rename it to “blog”:
mv wordpress blog
mv wordpress blog
Create the WordPress wp-config.php file:
cd blog
mv wp-config-sample.php wp-config.php
vi wp-config.php
cd blog
mv wp-config-sample.php wp-config.php
vi wp-config.php
Open a Browser and access your blog: http://ec2-50-17-14-16.compute-1.amazonaws.com/blog (Use your actual public DNS name). This should trigger the WordPress configuration process.
No comments:
Post a Comment