From bd9d05a73e1402f55a6ef198beb44d70d35305fb Mon Sep 17 00:00:00 2001 From: Tom Leavitt Date: Thu, 10 Aug 2017 11:36:11 -0700 Subject: [PATCH 1/2] Update the tutorial Creating a WordPress Server for stateless Replace all occurrences of /usr/share/httpd/htdocs with /var/www/html as defined in the Creating a LAMP Server tutorial stateless modifications --- source/clear-linux/tutorials/wp-install/wp-install.rst | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/source/clear-linux/tutorials/wp-install/wp-install.rst b/source/clear-linux/tutorials/wp-install/wp-install.rst index c93264a8..5a0f06f0 100644 --- a/source/clear-linux/tutorials/wp-install/wp-install.rst +++ b/source/clear-linux/tutorials/wp-install/wp-install.rst @@ -54,7 +54,7 @@ We are setting up a WordPress blog which can be accessed at: http:///blog To accomplish this setup, we must put the WordPress components in the -:file:`/usr/share/httpd/htdocs/blog` directory. +:file:`/var/www/html/blog` directory. Let us get started: @@ -64,7 +64,7 @@ Let us get started: .. code-block:: console - cd /usr/share/httpd/htdocs + cd /var/www/html 2. To download the latest version of WordPress, enter the following command: @@ -72,7 +72,7 @@ Let us get started: sudo curl -O https://wordpress.org/latest.tar.gz -3. To extract the all the files and directories from the downloaded file, +3. To extract all the files and directories from the downloaded file, enter the following command: .. code-block:: console @@ -96,7 +96,7 @@ Setting up WordPress -------------------- With the WordPress components loaded into the -:file:`/usr/share/httpd/htdocs/blog` directory, we can set everything up. +:file:`/var/www/html/blog` directory, we can set everything up. Instead of editing the :file:`wp_config.php` file manually, we are using the web-based configuration tool to setup the database name and user. We created From a64e18c056cde838da3750befa3f44728ea8b6e2 Mon Sep 17 00:00:00 2001 From: Tom Leavitt Date: Mon, 14 Aug 2017 09:43:40 -0700 Subject: [PATCH 2/2] Additional updates to clean up text Additional changes to add appropriate labels to file tags --- .../web-server-install/web-server-install.rst | 32 ++++++++++--------- 1 file changed, 17 insertions(+), 15 deletions(-) diff --git a/source/clear-linux/tutorials/web-server-install/web-server-install.rst b/source/clear-linux/tutorials/web-server-install/web-server-install.rst index 80268c77..1b46b891 100644 --- a/source/clear-linux/tutorials/web-server-install/web-server-install.rst +++ b/source/clear-linux/tutorials/web-server-install/web-server-install.rst @@ -79,9 +79,9 @@ Change the Default Configuration and Data Directory |CL| is designed to be a stateless operating system which means that you will need to create an optional configuration file. The default location of the -Apache configuration file, httpd.conf, is located in the -/etc/share/defaults/httpd directory, which can be overwritten as part of the -stateless paradigm. This default .conf file includes the following directives +Apache configuration file, :file:`httpd.conf`, is located in the +:file:`/etc/share/defaults/httpd` directory, which can be overwritten as part of the +stateless paradigm. This default :file:`.conf` file includes the following directives that allow for additional locations of configuration definitions: .. code-block:: console @@ -93,12 +93,12 @@ that allow for additional locations of configuration definitions: IncludeOptional /etc/httpd/conf.modules.d/*.conf -For this tutorial, we will create the directory structure for /etc/httpd/conf.d -and then create the httpd.conf file within /etc/httpd/conf.d directory and -include the variable DocumentRoot. +For this tutorial, we will create the directory structure for :file:`/etc/httpd/conf.d` +and then create the :file:`httpd.conf` file within :file:`/etc/httpd/conf.d` directory and +include the variable ``DocumentRoot``. Using your favorite editor, copy the content listed below into the new file -:file:`/etc/httpd/conf.d/httpd.conf` +:file:`/etc/httpd/conf.d/httpd.conf`. .. code-block:: console @@ -108,7 +108,7 @@ Using your favorite editor, copy the content listed below into the new file DocumentRoot “/var/www/html” # - # Releax access to content within /var/www/html for this tutorial + # Relax access to content within /var/www/html for this tutorial # AllowOverride none @@ -116,8 +116,9 @@ Using your favorite editor, copy the content listed below into the new file -Finally, let’s create the new DocumentRoot directory structure and copy the -index.html file from /usr/share/httpd/htdocs directory to /var/www/html. +Finally, let’s create the new ``DocumentRoot`` directory structure and copy the +:file:`index.html` file from :file:`/usr/share/httpd/htdocs` directory to +:file:`/var/www/html`. .. code-block:: console @@ -127,10 +128,11 @@ index.html file from /usr/share/httpd/htdocs directory to /var/www/html. To make sure that we have everything set correctly, let’s edit the new -index.html file with your favorite editor and change the text from -“It works” to “It works in it’s new location”. +:file:`index.html` file with your editor and change the text from +``It works`` to ``It works in it’s new location``. -With the new configuration files in place, you will need to stop and then restart the httpd.service +With the new configuration files in place, you will need to stop and then +restart the ``httpd.service``. .. code-block:: console @@ -145,7 +147,7 @@ Installing PHP With Apache installed, you can display static web pages. However, enabling PHP allows dynamic webpages to be generated and displayed. To add this -functionality to your web server we need to install PHP5 on your system. +functionality to your web server we need to install PHP on your system. To get the php components, enter the following command: @@ -165,7 +167,7 @@ To enable PHP, enter the following commands: After restarting the Apache service, we can test our PHP installation. 1. Create a file named :file:`phpinfo.php` in the - :file:`/var/www/html/` directory using your favorite editor. + :file:`/var/www/html/` directory using your editor. 2. Add the following line to the file: