<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>RobotSystematic &#187; Wordpress</title>
	<atom:link href="http://www.robotsystematic.com/tag/wordpress/feed" rel="self" type="application/rss+xml" />
	<link>http://www.robotsystematic.com</link>
	<description>Ubuntu, PHP, MySQL, Zend Framework, and other geekdom</description>
	<lastBuildDate>Thu, 09 Sep 2010 10:28:45 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Howto: WordPress on SliceHost or VPS with SFTP and SSH</title>
		<link>http://www.robotsystematic.com/2009/howto/howto-wordpress-on-slicehost-vps-with-sftp-ssh</link>
		<comments>http://www.robotsystematic.com/2009/howto/howto-wordpress-on-slicehost-vps-with-sftp-ssh#comments</comments>
		<pubDate>Sat, 20 Jun 2009 14:14:14 +0000</pubDate>
		<dc:creator>snek</dc:creator>
				<category><![CDATA[Howto]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<category><![CDATA[Wordpress]]></category>

		<guid isPermaLink="false">http://www.robotsystematic.com/?p=11</guid>
		<description><![CDATA[Let me start off by explaining why I wrote this tutorial. I have been hosting with SliceHost for quite some time now, and decided to mess around with Wordpress a bit instead of building something from scratch. After downloading and installing Wordpress I noticed it wanted FTP login details to install plugins etc from the Admin interface. That was a problem as I only have SSH / SFTP acces. (I never setup an FTP server because it would just take up more memory, I have a 256MB slice/vps.) Anyways, I was in a bit of a pickle, I didn't want to have to upload each plugin by hand and then manually install through the admin section. Then I found some tutorials on how to set up SSH support in Wordpress, but they were a bit unclear. Hence my reason for writing this.]]></description>
			<content:encoded><![CDATA[<h2>Introduction</h2>
<p>Let me start off by explaining why I wrote this tutorial. I have been hosting with <a title="SliceHost" href="http://www.slicehost.com/?referrer=cf0b047ee99fda19d909f2ed72b5d629" target="_blank">SliceHost</a> for quite some time now, and decided to mess around with WordPress a bit instead of building something from scratch. After downloading and installing WordPress I noticed it wanted FTP login details to install plugins etc from the Admin interface. That was a problem as I only have SSH / SFTP acces. (I never setup an FTP server because it would just take up more memory, I have a 256MB slice/vps.) Anyways, I was in a bit of a pickle, I didn&#8217;t want to have to upload each plugin by hand and then manually install through the admin section. Then I found some tutorials on how to set up SSH support in WordPress, but they were a bit unclear. Hence my reason for writing this.</p>
<p><span id="more-11"></span></p>
<h2>Prerequisits</h2>
<ul>
<li>Apache 2</li>
<li>PHP5</li>
<li>MySQL5</li>
<li>Ubuntu (probably works on Debian too, or any deritive there of)</li>
<li>A document root ready to be used</li>
</ul>
<p>If you haven&#8217;t installed Apache, MySQL and PHP5 yet make sure you do that first.<br />
You can find many nice articles how to do so on <a title="SliceHost Articles" href="http://articles.slicehost.com" target="_blank">SliceHost Articles</a>.</p>
<h2>Let&#8217;s get started</h2>
<p>First we need to download and extract wordpress to where we want it installed.<br />
If you are not going to be doing this from command-line (using ssh, on a linux machine) skip this step or read up how to install using another method <a title="WordPress Famous 5-Minute Install" href="http://codex.wordpress.org/Installing_WordPress#Famous_5-Minute_Install" target="_blank">WordPress Famous 5 Minute Install</a></p>
<div class="code"># Go to your home dir<br />
cd ~</p>
<p># Download the latest wordpress version<br />
wget http://wordpress.org/latest.tar.gz</p>
<p># Unpack the file, this should create the wordpress dir<br />
tar xzf latest.tar.gz</p>
<p># Go into the wordpress dir<br />
cd wordpress</p>
<p># Copy all the files to where you want to install wordpress (document root is easiest)<br />
# BE SURE TO CHANGE THIS LINE<br />
<span>cp -R * /var/www/vhosts/username/domain.com/public</span></div>
<p>If this step doesn&#8217;t work due to permissions you might have to start the line above with sudo. Afterwards you will also probably need to set the right owner for the files, probably www-data:www-data (sudo chmod -R www-data:www-data /var/www/etc/etc/etc)</p>
<p>Now you run the installation.<br />
Follow the guide from <a title="Wordpress Step 5: Run the install script" href="http://codex.wordpress.org/Installing_WordPress#Step_5:_Run_the_Install_Script" target="_blank">Step 5: Running the Install Script</a>.</p>
<p>Now I will explain how to install libSSH2 which we will need to enable WordPress to install Plugins / Themes from the admin section without using normal FTP.</p>
<div class="code"># First make sure we have all necessary compilation software<br />
sudo aptitude update<br />
sudo aptitude install libgcrypt-dev build-essential autoconf</p>
<p># Go to your home dir<br />
cd ~</p>
<p># Download the source to libssh2 v1.1<br />
wget http://kent.dl.sourceforge.net/sourceforge/libssh2/libssh2-1.1.tar.gz</p>
<p># Unpack the file<br />
tar xzf libssh2-1.1.tar.gz</p>
<p># Go to the unpacked directory<br />
cd libssh2-1.1/</p>
<p># Configure it for your system<br />
./configure</p>
<p># Compile<br />
make</p>
<p># Install<br />
sudo make install</p></div>
<p>Now we will link Apache to libSSH2 by using PECL. This is the easiest way to do this, if you do not have PECL support you will want to look into that first. I&#8217;m not going to go into detail on how to install PECL, in Ubuntu it should be almost as easy as doing a: sudo aptitude install php-pear.</p>
<div class="code">sudo pecl install -f ssh2</div>
<p>In my case I had to run it the following way because I run Zend Server CE and PECL is only callable directly:</p>
<div class="code">sudo /usr/local/zend/bin/pecl install -f ssh2</div>
<p>Now you have to edit your php.ini to load the new extension. Open the php.ini file and search till you find <em>Dynamic Extensions</em> and add the following line:</p>
<div class="code">extension=ssh2.so</div>
<p>Now it&#8217;s time to restart Apache and everything should be working! <img src='http://www.robotsystematic.com/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /> </p>
<div class="code">sudo /etc/init.d/apache2 restart</div>
<p>When you now go to the admin page of your WordPress installation you will see that you now have the option to use SSH for Plugin installs. Of course you will need your username &amp; password for SSH to login. At times it&#8217;s a bit slow I&#8217;ve noticed, but don&#8217;t give up right away. If you don&#8217;t get an error message things should be OK <img src='http://www.robotsystematic.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>I have tested this on Ubuntu Hardy and Jaunty without problems.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.robotsystematic.com/2009/howto/howto-wordpress-on-slicehost-vps-with-sftp-ssh/feed</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
	</channel>
</rss>
