Merge lp:~evarlast/serverguide/wordpress into lp:~ubuntu-core-doc/serverguide/quantal

Proposed by Jay R. Wren on 2012-07-27
Status: Superseded
Proposed branch: lp:~evarlast/serverguide/wordpress
Merge into: lp:~ubuntu-core-doc/serverguide/quantal
Diff against target: 234 lines (+147/-13)
3 files modified
serverguide/C/databases.xml (+12/-12)
serverguide/C/lamp-applications.xml (+134/-0)
serverguide/C/web-servers.xml (+1/-1)
To merge this branch: bzr merge lp:~evarlast/serverguide/wordpress
Reviewer Review Type Date Requested Status
Peter Matulis 2012-07-27 Needs Fixing on 2012-09-20
Review via email: mp+117135@code.launchpad.net

This proposal has been superseded by a proposal from 2013-02-23.

Description of the Change

I was surprised that WordPress was not listed in the lamp applications section, so I wrote a wordpress sub section

To post a comment you must log in.
Peter Matulis (petermatulis) wrote :

XML does not validate. Please correct this today as String Freeze is upon us.

====
scripts/validate.sh serverguide/C/serverguide.xml
 --Validating serverguide/C/serverguide.xml ...
lamp-applications.xml:607: element para: validity error : Element a is not declared in para list of possible children
lamp-applications.xml:608: element a: validity error : No declaration for element a
lamp-applications.xml:608: element a: validity error : No declaration for attribute href of element a
Document serverguide/C/serverguide.xml does not validate
====

review: Needs Fixing
Doug Smythies (dsmythies) wrote :

Thanks for your good work on this new section. Would you consider having a look at, and trying to fix, the validation issues? While this merge proposal is for quantal, it would be great to get it into the 13.04 server guide.

Jay R. Wren (evarlast) wrote :

looking into it.

lp:~evarlast/serverguide/wordpress updated on 2013-03-03
87. By Jay R. Wren on 2013-02-23

oops, fixed a ahref that should have been ulink url

88. By Jay R. Wren on 2013-02-24

merging upstream

89. By Jay R. Wren on 2013-02-24

WordPress section: use a2ensite instead of ln -s & clarify config-VHOST.php file

90. By Jay R. Wren on 2013-03-02

merge with upstream

91. By Jay R. Wren on 2013-03-02

WordPress section: remove link to a blog

linking to blog documentation is not recommended. I've removed the link.

92. By Jay R. Wren on 2013-03-03

change wordpress references to MLA format

http://www.easybib.com/reference/guide/mla/website

Unmerged revisions

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'serverguide/C/databases.xml'
2--- serverguide/C/databases.xml 2012-04-06 20:16:46 +0000
3+++ serverguide/C/databases.xml 2012-07-27 20:53:22 +0000
4@@ -324,25 +324,25 @@
5 <para>By default, connection via TCP/IP is disabled.
6 PostgreSQL supports multiple client authentication methods.
7 IDENT authentication method is used for <application>postgres</application> and local users, unless otherwise configured.
8- Please refer <ulink url="http://www.postgresql.org/docs/8.4/static/admin.html">
9+ Please refer <ulink url="http://www.postgresql.org/docs/9.1/static/admin.html">
10 the PostgreSQL Administrator's Guide if you would like to configure alternatives like Kerberos</ulink>.
11 </para>
12 <para>The following discussion assumes that you wish to enable
13 TCP/IP connections and use the MD5 method for client
14 authentication. PostgreSQL configuration files are stored in the
15 <filename>/etc/postgresql/&lt;version&gt;/main</filename>
16- directory. For example, if you install PostgreSQL 8.4, the
17+ directory. For example, if you install PostgreSQL 9.1, the
18 configuration files are stored in the
19- <filename>/etc/postgresql/8.4/main</filename> directory.
20+ <filename>/etc/postgresql/9.1/main</filename> directory.
21 </para>
22 <tip>
23 <para>
24 To configure <emphasis>ident</emphasis>
25- authentication, add entries to the <filename>/etc/postgresql/8.4/main/pg_ident.conf</filename>
26+ authentication, add entries to the <filename>/etc/postgresql/9.1/main/pg_ident.conf</filename>
27 file. There are detailed comments in the file to guide you.
28 </para>
29 </tip>
30- <para>To enable TCP/IP connections, edit the file <filename>/etc/postgresql/8.4/main/postgresql.conf</filename></para>
31+ <para>To enable TCP/IP connections, edit the file <filename>/etc/postgresql/9.1/main/postgresql.conf</filename></para>
32 <para>
33 Locate the line <emphasis>#listen_addresses = 'localhost'</emphasis> and change it to:
34 </para>
35@@ -381,7 +381,7 @@
36 </screen>
37 <para>
38 After configuring the password, edit the file
39- <filename>/etc/postgresql/8.4/main/pg_hba.conf</filename> to use
40+ <filename>/etc/postgresql/9.1/main/pg_hba.conf</filename> to use
41 <emphasis>MD5</emphasis> authentication with the <emphasis>postgres</emphasis> user:
42 </para>
43
44@@ -395,12 +395,12 @@
45 restart <application>PostgreSQL</application>:
46 </para>
47 <screen>
48-<command>sudo /etc/init.d/postgresql-8.4 restart</command>
49+<command>sudo service postgresql restart</command>
50 </screen>
51 <warning>
52 <para>
53 The above configuration is not complete by any means. Please
54- refer <ulink url="http://www.postgresql.org/docs/8.4/static/admin.html">
55+ refer <ulink url="http://www.postgresql.org/docs/9.1/static/admin.html">
56 the PostgreSQL Administrator's Guide</ulink> to configure more parameters.
57 </para>
58 </warning>
59@@ -410,15 +410,15 @@
60 <itemizedlist>
61 <listitem>
62 <para>
63- As mentioned above the <ulink url="http://www.postgresql.org/docs/8.4/static/admin.html">Administrator's Guide</ulink>
64- is an excellent resource. The guide is also available in the <application>postgresql-doc-8.4</application> package.
65+ As mentioned above the <ulink url="http://www.postgresql.org/docs/9.1/static/admin.html">Administrator's Guide</ulink>
66+ is an excellent resource. The guide is also available in the <application>postgresql-doc-9.1</application> package.
67 Execute the following in a terminal to install the package:
68 </para>
69 <screen>
70-<command>sudo apt-get install postgresql-doc-8.4</command>
71+<command>sudo apt-get install postgresql-doc-9.1</command>
72 </screen>
73 <para>
74- To view the guide enter <command>file:///usr/share/doc/postgresql-doc-8.4/html/index.html</command> into the address
75+ To view the guide enter <command>file:///usr/share/doc/postgresql-doc-9.1/html/index.html</command> into the address
76 bar of your browser.
77 </para>
78 </listitem>
79
80=== modified file 'serverguide/C/lamp-applications.xml'
81--- serverguide/C/lamp-applications.xml 2012-04-06 20:16:46 +0000
82+++ serverguide/C/lamp-applications.xml 2012-07-27 20:53:22 +0000
83@@ -502,4 +502,138 @@
84
85 </sect2>
86 </sect1>
87+ <sect1 id="wordpress" status="review">
88+ <title>WordPress</title>
89+ <para>
90+ Wordpress is a blog tool, publishing platform and CMS
91+ implemented in PHP and licensed under the GNU GPLv2.
92+ </para>
93+ <sect2 id="wordpress-installation" status="review">
94+ <title>Installation</title>
95+ <para>To install <application>WordPress</application>, run the following
96+ comand in the command prompt:
97+ </para>
98+
99+<screen>
100+ <command>sudo apt-get install wordpress</command>
101+</screen>
102+
103+ <para>
104+ You should also install <application>apache2</application> web
105+ server and mysql server. For installing <application>apache2</application> web
106+ server, please refer to <xref linkend="http-installation"/>
107+ sub-section in <xref linkend="httpd"/> section.
108+ For installing <application>mysql</application> server, please refer
109+ to <xref linkend="mysql-installation"/> sub-section in
110+ <xref linkend="mysql"/> section.
111+ </para>
112+
113+ </sect2>
114+ <sect2 id="wordpress-configuration" status="review">
115+ <title>Configuration</title>
116+
117+ <para>
118+ For configuring your first WordPress application, configure an apache site.
119+ Open <filename>/etc/apache2/sites-available/wordpress</filename> and write the
120+ following lines:
121+ </para>
122+
123+ <programlisting>
124+ Alias /blog /usr/share/wordpress
125+ Alias /blog/wp-content /var/lib/wordpress/wp-content
126+ &lt;Directory /usr/share/wordpress&gt;
127+ Options FollowSymLinks
128+ AllowOverride Limit Options FileInfo
129+ DirectoryIndex index.php
130+ Order allow,deny
131+ Allow from all
132+ &lt;/Directory&gt;
133+ &lt;Directory /var/lib/wordpress/wp-content&gt;
134+ Options FollowSymLinks
135+ Order allow,deny
136+ Allow from all
137+ &lt;/Directory&gt;
138+ </programlisting>
139+
140+ <para>Enable this new WordPress site</para>
141+
142+<screen>
143+<command>cd /etc/apache2/sites-enabled</command>
144+<command>sudo ln -s ../sites-available/wordpress</command>
145+</screen>
146+
147+ <para>
148+ Once you configure the <application>apache2</application> web server and
149+ make it ready for your <application>WordPress</application>
150+ application, you should restart it. You
151+ can run the following command to restart the
152+ <application>apache2</application> web server:
153+ </para>
154+
155+<screen>
156+<command>sudo service apache2 restart</command>
157+</screen>
158+
159+ <para>
160+ Now configure <application>WordPress</application> to use a mysql database.
161+ Open <filename>/etc/wordpress/config-localhost.php</filename> file and write
162+ the following lines:
163+ </para>
164+
165+<programlisting>
166+&lt;?php
167+define('DB_NAME', 'wordpress');
168+define('DB_USER', 'wordpress');
169+define('DB_PASSWORD', 'yourpasswordhere');
170+define('DB_HOST', 'localhost');
171+define('WP_CONTENT_DIR', '/var/lib/wordpress/wp-content');
172+?&gt;
173+</programlisting>
174+ <para>Now create this mysql database. Open a temporary file with mysql commands
175+ <filename>wordpress.sql</filename> and write the following lines:
176+ </para>
177+<programlisting>
178+CREATE DATABASE wordpress;
179+GRANT SELECT,INSERT,UPDATE,DELETE,CREATE,DROP,ALTER
180+ON wordpress.*
181+TO wordpress@localhost
182+IDENTIFIED BY 'yourpasswordhere';
183+FLUSH PRIVILEGES;
184+</programlisting>
185+ <para>Execute these commands.</para>
186+<screen>
187+<command>cat wordpress.sql | sudo mysql --defaults-extra-file=/etc/mysql/debian.cnf</command>
188+</screen>
189+ <para>Your new <application>WordPress</application> can now be configured by visiting
190+<a href="http://localhost/blog/wp-admin/install.php">http://localhost/blog/wp-admin/install.php</a>.
191+Fill out the Site Title, username, password, and E-mail and click Install WordPress.
192+ </para>
193+ <para>Note the generated password (if applicable) and click the login password. Your
194+<application>WordPress</application> is now ready for use.
195+ </para>
196+ </sect2>
197+ <sect2 id="wordpress-references" status="review">
198+ <title>References</title>
199+
200+ <itemizedlist>
201+ <listitem>
202+ <para>
203+ For more information see the <ulink url="http://wordpress.com/">WordPress</ulink>.
204+ </para>
205+ </listitem>
206+ <listitem>
207+ <para>
208+ Also, see <ulink url="http://linux.justinhartman.com/Wordpress_Installation_on_Debian">
209+ WordPress Installation on Debian</ulink>.
210+ </para>
211+ </listitem>
212+ <listitem>
213+ <para>
214+ Also, see the <ulink url="https://help.ubuntu.com/community/WordPress">Ubuntu Wiki WordPress</ulink> page.
215+ </para>
216+ </listitem>
217+ </itemizedlist>
218+
219+ </sect2>
220+ </sect1>
221 </chapter>
222
223=== modified file 'serverguide/C/web-servers.xml'
224--- serverguide/C/web-servers.xml 2012-04-06 20:16:46 +0000
225+++ serverguide/C/web-servers.xml 2012-07-27 20:53:22 +0000
226@@ -904,7 +904,7 @@
227 <para>
228 Using the excellent access control features of Squid, you may configure use of Internet services proxied by Squid
229 to be available only during normal business hours. For example, we'll illustrate access by employees of a business
230- which is operating between 9:00AM and 5:00PM, Monday through Friday, and which uses the 10.1.42.0/42 subnetwork:
231+ which is operating between 9:00AM and 5:00PM, Monday through Friday, and which uses the 10.1.42.0/24 subnetwork:
232 </para>
233 <para>
234 Add the following to the <emphasis role="bold">bottom</emphasis> of the ACL section of your <filename>/etc/squid/squid.conf</filename> file:

Subscribers

People subscribed via source and target branches