<?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>workbench @ haefelinger.it &#187; plesk</title>
	<atom:link href="http://workbench.haefelinger.it/archives/category/admin/plesk/feed" rel="self" type="application/rss+xml" />
	<link>http://workbench.haefelinger.it</link>
	<description>Notes, thouhts and other stuff on software development</description>
	<lastBuildDate>Wed, 07 Apr 2010 07:02:31 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Adding A Plesk Event Handler</title>
		<link>http://workbench.haefelinger.it/archives/177</link>
		<comments>http://workbench.haefelinger.it/archives/177#comments</comments>
		<pubDate>Thu, 25 Feb 2010 15:46:31 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[plesk]]></category>

		<guid isPermaLink="false">http://workbench.haefelinger.it/?p=177</guid>
		<description><![CDATA[Plesk allows you to have a customized event handler. This is a rather useful feature cause it allows you to customize the way Plesk behaves. Take the meanwhile famous vhost_ssl.conf bug. Although documented in the manual, Plesk will not recognize an additional configuration file for an SSL/TLS port in a subdomain. Solutions have been proposed [...]]]></description>
			<content:encoded><![CDATA[<p>Plesk allows you to have a customized event handler. This is a rather useful feature cause it allows you to customize the way Plesk behaves. Take the meanwhile famous <code>vhost_ssl.conf </code>bug. Although documented in the manual, Plesk will not recognize an additional configuration file for an SSL/TLS port in a subdomain. Solutions have been proposed to manually change vhost.conf. That&#8217;s a forbidden fruit however, cause all it needs is a <code>websrvmng --reconfigure-all</code> to eliminate your changes. But as mentioned, just install a event handler which is triggered when a subdomain is created or updated. Such an event handler can be just a plain shell script.</p>
<p>However, when I tried to install such an event handler beast via <code>Plesk | Server | Event Handler | Add New Event Handler</code> I ended up in an error message like <code>Error: Some fields are empty or contain an improper value</code> for which add did not have any explanation. Much, very much later, I discovered that I had copied the path of my script to be executed via copy-n-paste into that Plesk command field. That copy contained whitespace at the end of the command, i.e. something like</p>
<pre>
/path/to/handler.sh\n
</pre>
<p>which is enough to make Please grumpy. What&#8217;s more, it&#8217;s all about whitespace (blanks, tabs, newline etc) at the end of a command while whitespace within the command is accept without any rumble:</p>
<pre>
echo > /dev/null
</pre>
<p>That works fine. </p>
<p><strong>Summary: </strong></p>
<blockquote><p>When entering an event handler command, make sure that there is no whitespace at the end of the command.
</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://workbench.haefelinger.it/archives/177/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Plesk</title>
		<link>http://workbench.haefelinger.it/archives/156</link>
		<comments>http://workbench.haefelinger.it/archives/156#comments</comments>
		<pubDate>Fri, 12 Feb 2010 11:17:22 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[apache httpd]]></category>
		<category><![CDATA[plesk]]></category>
		<category><![CDATA[apache_httpd]]></category>

		<guid isPermaLink="false">http://workbench.haefelinger.it/?p=156</guid>
		<description><![CDATA[Plesk is kind of freaky creature. Working with it can be a frustrating experience. Not when working with the graphical web interface. Used in that way, it&#8217;s easy to create/modify/remove sub-domains and other important tasks. However, the guys from Paralles do not expect apache to server something else than static pages. How else can it [...]]]></description>
			<content:encoded><![CDATA[<p>Plesk is kind of freaky creature. Working with it can be a frustrating experience. Not when working with the graphical web interface. Used in that way, it&#8217;s easy to create/modify/remove sub-domains and other important tasks. However, the guys from Paralles do not expect apache to server something else than static pages. How else can it be explained, that touching a vhost.conf file is something that is described in appendix A, A<em>dvanced Features</em>, in the Plesk manual?</p>
<p>So just assume that you have create a new subdomain and you want to make your CSS files available via <code>/css</code> instead of going via some hardwired domain URL. So all you want to have is an alias like</p>
<pre>
Alias /css "/path/to/my/css/folder"
</pre>
<p>Ok, but where to enter? When you look at the folder structure and files created by Plesk it is by no means clear what to do. But hey, what are manuals good for anyway? What you discover is that Plesk created a folder like</p>
<pre>
  /path/to/<strong>domain</strong>/subdomains/<strong>subdomain</strong>/conf
</pre>
<p>for your <em>subdomain</em>. The folder is empty. <strong>It would be really great if Plesk would in addition create a README file in that folder.</strong> That file would then state something like this:<br />
<i><br />
To configure your subdomain, add herein a file name vhost.conf. Put any Apache configurations in this file you like but be aware that this file is being included in a virtual host definition.</p>
<p>Once you have have added vhost.conf, please reconfigure this subdomain so that your file is taken into account. You do this by</p>
<pre>
 $ /usr/local/psa/admin/sbin/websrvmng --reconfigure-all
</pre>
<p>You need to do this only once, because this command does nothing more than insert a Include statement in /path/to/<strong>domain</strong>/conf/http.include. But refrain from do it manually because websrvmng will rewrite that file from scratch on the next run.</p>
<p>Oh, and btw notice that regardless of what our manual says you can only have a vhost.conf in a subdomain&#8217;s conf folder. Any vhost_ssl.conf therein is not taken into account.
</pre>
<p>Good luck and have a nice day.<br />
</i><br />
Unfortunately, that README file is missing.  Unfortunately.</p>
]]></content:encoded>
			<wfw:commentRss>http://workbench.haefelinger.it/archives/156/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
