<?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>P0L0&#039;s Blog &#187; debian</title>
	<atom:link href="http://p0l0.binware.org/index.php/tag/debian/feed/" rel="self" type="application/rss+xml" />
	<link>http://p0l0.binware.org</link>
	<description>Opensource Projects and IT experiences</description>
	<lastBuildDate>Sun, 30 Oct 2011 08:39:29 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=</generator>
		<item>
		<title>Spidermonkey &#8211; Execute javascript from console</title>
		<link>http://p0l0.binware.org/index.php/2010/05/24/spidermonkey-execute-javascript-from-console/</link>
		<comments>http://p0l0.binware.org/index.php/2010/05/24/spidermonkey-execute-javascript-from-console/#comments</comments>
		<pubDate>Mon, 24 May 2010 06:09:26 +0000</pubDate>
		<dc:creator>P0L0</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[GNU/Linux]]></category>
		<category><![CDATA[debian]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://p0l0.binware.org/?p=693</guid>
		<description><![CDATA[SpiderMonkey is the code-name for the Mozilla&#8217;s C implementation of JavaScript. This is useful to test part of our JavaScript from the console or in scripts. In Debian we have a package called spidermonkey-bin. apt-get install spidermonkey-bin After installing you will have a program called smjs. If you start the program without parameters you will [...]]]></description>
			<content:encoded><![CDATA[<p>SpiderMonkey is the code-name for the Mozilla&#8217;s C implementation of JavaScript. This is useful to test part of our JavaScript from the console or in scripts.</p>
<p>In Debian we have a package called <strong>spidermonkey-bin</strong>.</p>
<p><span id="more-693"></span></p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">apt-get</span> <span style="color: #c20cb9; font-weight: bold;">install</span> spidermonkey-bin</pre></div></div>

<p><div style="margin-left: -20px; margin-top: 20px; margin-bottom: 20px;"><script type="text/javascript"><!--
google_ad_client = "ca-pub-5682258244719056";
/* Inline Post */
google_ad_slot = "6946080416";
google_ad_width = 468;
google_ad_height = 60;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script></div></p>
<p>After installing you will have a program called <strong>smjs</strong>.</p>
<p>If you start the program without parameters you will get a <strong>Javascript shell</strong>, in which you can write and test javascript.</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span>smjs
js<span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #000000; font-weight: bold;">function</span> <span style="color: #7a0874; font-weight: bold;">test</span><span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> <span style="color: #7a0874; font-weight: bold;">&#123;</span>
print<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #ff0000;">'test'</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>;
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
js<span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #7a0874; font-weight: bold;">test</span>
<span style="color: #000000; font-weight: bold;">function</span> <span style="color: #7a0874; font-weight: bold;">test</span><span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> <span style="color: #7a0874; font-weight: bold;">&#123;</span>
    print<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #ff0000;">&quot;test&quot;</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>;
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
js<span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #7a0874; font-weight: bold;">test</span><span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>;
<span style="color: #7a0874; font-weight: bold;">test</span>
js<span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #000000; font-weight: bold;">function</span> <span style="color: #7a0874; font-weight: bold;">test</span><span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> <span style="color: #7a0874; font-weight: bold;">&#123;</span>
print<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #ff0000;">'test'</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>;
test2<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">123</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>;
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
js<span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #000000; font-weight: bold;">function</span> test2<span style="color: #7a0874; font-weight: bold;">&#40;</span>param<span style="color: #7a0874; font-weight: bold;">&#41;</span> <span style="color: #7a0874; font-weight: bold;">&#123;</span>
print <span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #ff0000;">'test2: '</span> + param<span style="color: #7a0874; font-weight: bold;">&#41;</span>;
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
js<span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #7a0874; font-weight: bold;">test</span><span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>;
<span style="color: #7a0874; font-weight: bold;">test</span>
test2: <span style="color: #000000;">123</span>
js<span style="color: #000000; font-weight: bold;">&gt;</span></pre></div></div>

<p>To exit the shell, just press &#8220;<strong>Ctrl+D</strong>&#8220;.</p>
<p>It&#8217;s important to note that in spidermonkey you doesn&#8217;t have the &#8220;<strong>document</strong>&#8221; Object. If you want to print out text, you cant use <strong>document.write</strong>, you should use <strong>print</strong>.</p>

<div class="wp_syntax"><div class="code"><pre class="javascript" style="font-family:monospace;">document.<span style="color: #000066; font-weight: bold;">write</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'test'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #006600; font-style: italic;">// In browser</span>
<span style="color: #000066;">print</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'test'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #006600; font-style: italic;">//spidermonkey</span></pre></div></div>

<p>You can also make <strong>smjs</strong> to execute the content of a file.</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">$ <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span>smjs test-local.js
Rand: <span style="color: #000000;">407</span>
Old: <span style="color: #000000;">600</span>
New: <span style="color: #000000;">800</span>
Result: old</pre></div></div>

<p><div style="margin-left: -20px; margin-top: 20px; margin-bottom: 20px;"><script type="text/javascript"><!--
google_ad_client = "ca-pub-5682258244719056";
/* Inline Post */
google_ad_slot = "6946080416";
google_ad_width = 468;
google_ad_height = 60;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script></div></p>
]]></content:encoded>
			<wfw:commentRss>http://p0l0.binware.org/index.php/2010/05/24/spidermonkey-execute-javascript-from-console/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Multiples proyectos con trac y svn usando HTTPS</title>
		<link>http://p0l0.binware.org/index.php/2006/10/03/multiples-proyectos-con-trac-y-svn-usando-https/</link>
		<comments>http://p0l0.binware.org/index.php/2006/10/03/multiples-proyectos-con-trac-y-svn-usando-https/#comments</comments>
		<pubDate>Tue, 03 Oct 2006 17:51:55 +0000</pubDate>
		<dc:creator>P0L0</dc:creator>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[GNU/Linux]]></category>
		<category><![CDATA[binware]]></category>
		<category><![CDATA[debian]]></category>
		<category><![CDATA[hosting]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[svn]]></category>
		<category><![CDATA[trac]]></category>

		<guid isPermaLink="false">http://p0l0.binware.org/index.php/2006/10/03/multiples-proyectos-con-trac-y-svn-usando-https/</guid>
		<description><![CDATA[Voy a explicar como montar el sistema de gestion de proyectos trac y subversion usando https para trabajar con subversion. Yo lo he montado en una debian usando apache2, asi que lo primero que necesitamos es instalar todo lo necesario apt-get install trac subversion apache2 subversion libapache2-svn libapache2-mod-python2.3 Una vez descargado e instalado creamos el [...]]]></description>
			<content:encoded><![CDATA[<p>Voy a explicar como montar el sistema de gestion de proyectos <a target="_blank" title="Trac" href="http://trac.edgewall.com/">trac</a> y <a target="_blank" title="Subversion" href="http://subversion.tigris.org/">subversion</a> usando https para trabajar con subversion. Yo lo he montado en una debian usando apache2, asi que lo primero que necesitamos es instalar todo lo necesario</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">apt-get</span> <span style="color: #c20cb9; font-weight: bold;">install</span> trac subversion apache2 subversion libapache2-svn libapache2-mod-python2.3</pre></div></div>

<p>Una vez descargado e instalado creamos el certificado necesario para usar tanto trac y subversion bajo https. Entra en el directorio <strong>/etc/apache2/ssl</strong> y ejecuta lo siguiente:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">openssl genrsa <span style="color: #660033;">-des3</span> <span style="color: #660033;">-out</span> server.key <span style="color: #000000;">1024</span>
openssl req <span style="color: #660033;">-new</span> <span style="color: #660033;">-key</span> server.key <span style="color: #660033;">-out</span> server.csr
<span style="color: #c20cb9; font-weight: bold;">cp</span> server.key server.key.org
openssl rsa <span style="color: #660033;">-in</span> server.key.org <span style="color: #660033;">-out</span> server.key
openssl x509 <span style="color: #660033;">-req</span> <span style="color: #660033;">-days</span> <span style="color: #000000;">365</span> <span style="color: #660033;">-in</span> server.csr <span style="color: #660033;">-signkey</span> server.key <span style="color: #660033;">-out</span> server.crt</pre></div></div>

<p>Ahora ya tenemos listo los certificados, asi que ahora solo nos queda configurar el apache. Yo he creado un trac.dominio.ext y un svn.dominio.ext para hacer esto, pero esto va a gusto de cada uno. Yo como uso dos subdominios distintos, lo tengo en ficheros separados.</p>
<p>Primero editaremos el trac, asi que creamos el fichero <strong>/etc/apache2/sites-available/trac.domain.ext</strong></p>

<div class="wp_syntax"><div class="code"><pre class="ini" style="font-family:monospace;">NameVirtualHost *:<span style="">443</span>
&lt;VirtualHost *:<span style="">443</span>&gt;
#Activate SSL
SSLEngine on
&nbsp;
SSLCertificateFile    /etc/apache2/ssl/server.crt
SSLCertificateKeyFile /etc/apache2/ssl/server.key
&nbsp;
#VirtualHost Servername
ServerName trac.domain.ext
ServerAdmin trac@domain.ext
&nbsp;
DocumentRoot /opt/projects/trac
&nbsp;
#Authentication
&lt;Location /&gt;
AuthType Basic
AuthName <span style="color: #933;">&quot;Trac&quot;</span>
AuthUserFile /opt/projects/.htpasswd
Require valid-user
&nbsp;
#Trac
SetHandler mod_python
PythonHandler trac.web.modpython_frontend
PythonOption TracEnvParentDir /opt/projects/trac/
PythonOption TracUriRoot /
&nbsp;
&lt;/Location&gt;
&lt;/VirtualHost&gt;</pre></div></div>

<p>El fichero no necesita demasiada explicacion, simplemente le decimos que active el SSL, que pida autentificacion y cargamos el modulo del trac y le especificamos el path de donde estan todos nuestros proyectos.</p>
<p>Ahora vamos con el fichero <strong>/etc/apache2/sites-available/svn.domain.ext</strong></p>

<div class="wp_syntax"><div class="code"><pre class="ini" style="font-family:monospace;">NameVirtualHost *:<span style="">443</span>
&lt;VirtualHost *:<span style="">443</span>&gt;
#Activate SSL
SSLEngine on
&nbsp;
SSLCertificateFile    /etc/apache2/ssl/server.crt
SSLCertificateKeyFile /etc/apache2/ssl/server.key
&nbsp;
#VirtualHost Servername
ServerName svn.domain.ext
ServerAdmin svn@domain.ext
&nbsp;
DocumentRoot /opt/projects/svn
&lt;Location /&gt;
DAV svn
&nbsp;
#Authentication
AuthType Basic
AuthName <span style="color: #933;">&quot;Subversion&quot;</span>
AuthUserFile /opt/projects/.htpasswd
Require valid-user
&nbsp;
#Subversion
SVNParentPath /opt/projects/svn
SVNListParentPath on
SVNAutoVersioning On
&lt;/Location&gt;
&nbsp;
&lt;LocationMatch <span style="color: #933;">&quot;/.+&quot;</span>&gt;
#Subversion permission file
AuthzSVNAccessFile /opt/projects/svn/.htpasswd
&lt;/LocationMatch&gt;
&lt;/VirtualHost&gt;</pre></div></div>

<p>Es importante separar el <strong>AuthzSVNAccessFile</strong> de <strong>&lt;Location /&gt;</strong> ya que sino no listara todos los proyectos en http://svn.domain.ext/ por problemas de permisos.</p>
<p>Ahora que tenemos estos ficheros listos, hay que activar el modulo de ssl en el apache2 y los dos dominios.</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">vi</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>apache2<span style="color: #000000; font-weight: bold;">/</span>ports.conf</pre></div></div>


<div class="wp_syntax"><div class="code"><pre class="ini" style="font-family:monospace;">&lt;IfModule mod_ssl.c&gt;
Listen <span style="">443</span>
&lt;/IfModule&gt;</pre></div></div>


<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">cd</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>apache2<span style="color: #000000; font-weight: bold;">/</span>mods-enabled
<span style="color: #c20cb9; font-weight: bold;">ln</span> <span style="color: #660033;">-s</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>apache2<span style="color: #000000; font-weight: bold;">/</span>mods-available<span style="color: #000000; font-weight: bold;">/</span>dav.load .
<span style="color: #c20cb9; font-weight: bold;">ln</span> <span style="color: #660033;">-s</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>apache2<span style="color: #000000; font-weight: bold;">/</span>mods-available<span style="color: #000000; font-weight: bold;">/</span>dav_svn.load .
<span style="color: #c20cb9; font-weight: bold;">ln</span> <span style="color: #660033;">-s</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>apache2<span style="color: #000000; font-weight: bold;">/</span>mods-available<span style="color: #000000; font-weight: bold;">/</span>mod_python.load .
<span style="color: #c20cb9; font-weight: bold;">ln</span> <span style="color: #660033;">-s</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>apache2<span style="color: #000000; font-weight: bold;">/</span>mods-available<span style="color: #000000; font-weight: bold;">/</span>ssl.conf .
<span style="color: #c20cb9; font-weight: bold;">ln</span> <span style="color: #660033;">-s</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>apache2<span style="color: #000000; font-weight: bold;">/</span>mods-available<span style="color: #000000; font-weight: bold;">/</span>ssl.load .
&nbsp;
<span style="color: #7a0874; font-weight: bold;">cd</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>apache2<span style="color: #000000; font-weight: bold;">/</span>sites-enabled
<span style="color: #c20cb9; font-weight: bold;">ln</span> <span style="color: #660033;">-s</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>apache2<span style="color: #000000; font-weight: bold;">/</span>sites-available<span style="color: #000000; font-weight: bold;">/</span>svn.domain.ext 001-svn.domain.ext
<span style="color: #c20cb9; font-weight: bold;">ln</span> <span style="color: #660033;">-s</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>apache2<span style="color: #000000; font-weight: bold;">/</span>sites-available<span style="color: #000000; font-weight: bold;">/</span>trac.domain.ext 001-trac.domain.ext</pre></div></div>

<p>Ahora vamos a crear un proyecto de prueba</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">mkdir</span> <span style="color: #660033;">-p</span> <span style="color: #000000; font-weight: bold;">/</span>opt<span style="color: #000000; font-weight: bold;">/</span>projects<span style="color: #000000; font-weight: bold;">/</span><span style="color: #c20cb9; font-weight: bold;">svn</span>
<span style="color: #c20cb9; font-weight: bold;">mkdir</span> <span style="color: #660033;">-p</span> <span style="color: #000000; font-weight: bold;">/</span>opt<span style="color: #000000; font-weight: bold;">/</span>projects<span style="color: #000000; font-weight: bold;">/</span>trac
<span style="color: #c20cb9; font-weight: bold;">svnadmin</span> create <span style="color: #000000; font-weight: bold;">/</span>opt<span style="color: #000000; font-weight: bold;">/</span>projects<span style="color: #000000; font-weight: bold;">/</span>svn<span style="color: #000000; font-weight: bold;">/</span>NewProject
trac-admin <span style="color: #000000; font-weight: bold;">/</span>opt<span style="color: #000000; font-weight: bold;">/</span>projects<span style="color: #000000; font-weight: bold;">/</span>trac<span style="color: #000000; font-weight: bold;">/</span>NewProject initenv</pre></div></div>


<div class="wp_syntax"><div class="code"><pre class="ini" style="font-family:monospace;">Project Name <span style="color: #000066; font-weight:bold;"><span style="">&#91;</span>My Project<span style="">&#93;</span></span>&gt; NewProject
Database connection string <span style="color: #000066; font-weight:bold;"><span style="">&#91;</span>sqlite:db/trac.db<span style="">&#93;</span></span>&gt;
Path to repository <span style="color: #000066; font-weight:bold;"><span style="">&#91;</span>/var/svn/test<span style="">&#93;</span></span>&gt; /opt/projects/svn/NewProject
Templates directory <span style="color: #000066; font-weight:bold;"><span style="">&#91;</span>/usr/share/trac/templates<span style="">&#93;</span></span>&gt;
Creating and Initializing Project
Configuring Project
trac.repository_dir
trac.database
trac.templates_dir
project.name
Installing default wiki pages
..............</pre></div></div>

<pre lang="bash"
chown -R www-data:www-data /opt/projects/
</pre>
<p>Ahora creamos los ficheros de acceso de usuarios.</p>
</pre>
<pre lang="bash>
htpasswd -c /opt/projects/.htpasswd user1
htpasswd /opt/projects/.htpasswd user2
</pre>
<p>Y el archivo de permisos de subversion, que tiene el siguiente formato</p>

<div class="wp_syntax"><div class="code"><pre class="ini" style="font-family:monospace;"><span style="color: #000066; font-weight:bold;"><span style="">&#91;</span>Repositorio:/Path<span style="">&#93;</span></span>
<span style="color: #000099;">user</span> <span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;"> <span style="color: #000066; font-weight:bold;"><span style="">&#91;</span> <span style="">&#91;</span>r<span style="">&#91;</span>w<span style="">&#93;</span><span style="">&#93;</span><span style="">&#93;</span></span></span></pre></div></div>

<p>Por ejemplo, queremos que el user1 pueda leer y escribir, el user2 leer, y anonymous nada (no deberia haber anonymous ya que el htpasswd no los deja pasar, pero siempre viene bien protegerse por si acaso), el fichero quedaria asi</p>

<div class="wp_syntax"><div class="code"><pre class="ini" style="font-family:monospace;"><span style="color: #000066; font-weight:bold;"><span style="">&#91;</span>NewProject:/<span style="">&#93;</span></span>
<span style="color: #000099;">user1</span> <span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;"> rw</span>
<span style="color: #000099;">user2</span> <span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;"> r</span>
* <span style="color: #000066; font-weight:bold;">=</span></pre></div></div>

<p>Ahora ya tenemos todo listo, podemos instalar el modulo <a target="_blank" title="Trac Web Admin" href="http://trac.edgewall.org/wiki/WebAdmin">TracWebAdmin</a> para que sea mas facil la administracion del trac.</p>
]]></content:encoded>
			<wfw:commentRss>http://p0l0.binware.org/index.php/2006/10/03/multiples-proyectos-con-trac-y-svn-usando-https/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>/etc/apt/preferences para paquetes locales</title>
		<link>http://p0l0.binware.org/index.php/2006/05/01/etcaptpreferences-para-paquetes-locales/</link>
		<comments>http://p0l0.binware.org/index.php/2006/05/01/etcaptpreferences-para-paquetes-locales/#comments</comments>
		<pubDate>Mon, 01 May 2006 20:47:05 +0000</pubDate>
		<dc:creator>P0L0</dc:creator>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[GNU/Linux]]></category>
		<category><![CDATA[debian]]></category>
		<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://p0l0.binware.org/index.php/2006/05/01/etcaptpreferences-para-paquetes-locales/</guid>
		<description><![CDATA[Bueno el otro dia despues de compilar a mano postfix y courier con sus respectivas modificaciones, cada vez que hacia un apt-get update ; apt-get upgrade me decia que queria instalar postfix* y courier* con una version nueva&#8230; asi que despues de buscar y trastear descubri que el nombre de release de los paquetes compilados [...]]]></description>
			<content:encoded><![CDATA[<p>Bueno el otro dia despues de compilar a mano postfix y courier con sus respectivas modificaciones, cada vez que hacia un <strong>apt-get update ; apt-get upgrade</strong> me decia que queria instalar postfix* y courier* con una version nueva&#8230; asi que despues de buscar y trastear descubri que el nombre de release de los paquetes compilados a mano es &#8220;now&#8221; con lo cual puse lo siguiente en <strong>/etc/apt/preferences</strong></p>

<div class="wp_syntax"><div class="code"><pre class="ini" style="font-family:monospace;">Package: postfix*
Pin: release a<span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;">now</span>
Pin-Priority: <span style="">999</span>
&nbsp;
Package: courier*
Pin: release a<span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;">now</span>
Pin-Priority: <span style="">999</span></pre></div></div>

]]></content:encoded>
			<wfw:commentRss>http://p0l0.binware.org/index.php/2006/05/01/etcaptpreferences-para-paquetes-locales/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Postfix+VDA</title>
		<link>http://p0l0.binware.org/index.php/2006/03/05/postfixvda/</link>
		<comments>http://p0l0.binware.org/index.php/2006/03/05/postfixvda/#comments</comments>
		<pubDate>Sun, 05 Mar 2006 00:01:00 +0000</pubDate>
		<dc:creator>P0L0</dc:creator>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[GNU/Linux]]></category>
		<category><![CDATA[binware]]></category>
		<category><![CDATA[debian]]></category>
		<category><![CDATA[hosting]]></category>
		<category><![CDATA[postfix]]></category>
		<category><![CDATA[quota]]></category>

		<guid isPermaLink="false">http://p0l0.binware.org/index.php/2006/03/05/postfixvda/</guid>
		<description><![CDATA[Esto era una de las cosas que tenia pendiente de poner en el server hosting, y ultimamente ha habido mucha gente que superaba de mucho el limite, asi que me he puesto a configurar e instalar postfix con el parch VDA para poner limite de tamaño a los buzones. Como tengo ahora mismo todo configurado [...]]]></description>
			<content:encoded><![CDATA[<p>Esto era una de las cosas que tenia pendiente de poner en el server hosting, y ultimamente ha habido mucha gente que superaba de mucho el limite, asi que  me he puesto a configurar e instalar postfix con el parch VDA para poner limite de tamaño a los buzones.</p>
<p>Como tengo ahora mismo todo configurado con los paquetes de debian, he pensado que lo mejor es parchear los propios paquetes de debian, y aqui estan los pasos que he seguido:</p>
<ol>
<li>Instalo todas las utilidades necesarias para poder compilar y crear el paquete de postfix.

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">apt-get</span> <span style="color: #c20cb9; font-weight: bold;">install</span> build-essential dpkg-dev fakeroot debhelper po-debconf dpatch lsb-release libdb4.3-dev libgdbm-dev libldap2-dev libpcre3-dev libmysqlclient15-dev libsasl2-dev libpq-dev</pre></div></div>

</li>
<li>Nos bajamos el codigo fuente del postfix (Conviene hacerlo en /usr/src ya que lo descarga en el directorio actual)

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">apt-get</span> <span style="color: #7a0874; font-weight: bold;">source</span> postfix</pre></div></div>

</li>
<li>Nos bajamos el ultimo parche disponible para nuestra version de <a href="http://web.onda.com.br/nadal/">http://web.onda.com.br/nadal/</a>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">wget</span> http:<span style="color: #000000; font-weight: bold;">//</span>web.onda.com.br<span style="color: #000000; font-weight: bold;">/</span>nadal<span style="color: #000000; font-weight: bold;">/</span>postfix<span style="color: #000000; font-weight: bold;">/</span>VDA<span style="color: #000000; font-weight: bold;">/</span>postfix-2.2.8-vda.patch.gz</pre></div></div>

</li>
<li>Parcheamos el codigo

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">gunzip</span> postfix-2.2.8-vda.patch.gz
<span style="color: #c20cb9; font-weight: bold;">patch</span> <span style="color: #660033;">-p1</span></pre></div></div>

</li>
<li>Compilamos

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">dpkg-buildpackage</pre></div></div>

</li>
<li>Instalamos los paquetes generados

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">dpkg</span> <span style="color: #660033;">-i</span> postfix_2.2.8-<span style="color: #000000;">9</span>_i386.deb
<span style="color: #c20cb9; font-weight: bold;">dpkg</span> <span style="color: #660033;">-i</span> postfix-mysql_2.2.8-<span style="color: #000000;">9</span>_i386.deb</pre></div></div>

</li>
<li>Configuramos postfix</li>
</ol>
<ol>
<li>main.cf

<div class="wp_syntax"><div class="code"><pre class="ini" style="font-family:monospace;"><span style="color: #000099;">virtual_mailbox_limit_override</span><span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;">yes</span>
#Use IMAP compatible files
<span style="color: #000099;">virtual_maildir_extended</span><span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;">yes</span>
#Create maildirsize files
<span style="color: #000099;">virtual_create_maildirsize</span><span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;">yes</span>
#Bounce mails overquota
<span style="color: #000099;">virtual_overquota_bounce</span><span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;">yes</span>
#MySQL info to get user quota
<span style="color: #000099;">virtual_mailbox_limit_maps</span><span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;">mysql:/etc/postfix/quota.cf</span>
#Count Trash
<span style="color: #000099;">virtual_trash_count</span><span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;">yes</span>
<span style="color: #000099;">virtual_trash_name</span><span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;">.Trash</span></pre></div></div>

</li>
<li>quota.cf

<div class="wp_syntax"><div class="code"><pre class="ini" style="font-family:monospace;"><span style="color: #000099;">user</span><span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;">mail</span>
<span style="color: #000099;">password</span><span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;">mailpassword</span>
<span style="color: #000099;">dbname</span><span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;">mail</span>
<span style="color: #000099;">table</span><span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;">users</span>
<span style="color: #000099;">hosts</span><span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;">localhost</span>
<span style="color: #000099;">where_field</span><span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;">address</span>
<span style="color: #000099;">select_field</span><span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;">quota</span></pre></div></div>

</li>
</ol>
<li>Configuramos courier</li>
<ol>
<li>authmysqlrc

<div class="wp_syntax"><div class="code"><pre class="ini" style="font-family:monospace;">MYSQL_QUOTA_FIELD quota</pre></div></div>

</li>
</ol>
<p>
Updated (2007/07/12): La nueva URL del patch VDA es http://vda.sourceforge.net/</p>
]]></content:encoded>
			<wfw:commentRss>http://p0l0.binware.org/index.php/2006/03/05/postfixvda/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Debian 64bits</title>
		<link>http://p0l0.binware.org/index.php/2005/03/08/debian-64bits/</link>
		<comments>http://p0l0.binware.org/index.php/2005/03/08/debian-64bits/#comments</comments>
		<pubDate>Tue, 08 Mar 2005 17:22:00 +0000</pubDate>
		<dc:creator>P0L0</dc:creator>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[64bits]]></category>
		<category><![CDATA[debian]]></category>
		<category><![CDATA[linux]]></category>

		<guid isPermaLink="false">http://p0l0.binware.org/index.php/2005/03/08/debian-64bits/</guid>
		<description><![CDATA[Hoy me ha tocado instalar una debian 64bits en un opteron. La verdad es que esta bastante currada, con el nuevo instalador de debian, te lo detecta todo solo y se instala perfectamente. El unico problema que he tenido es que ni el LILO ni el GRUB se han querido instalar, se ve que el [...]]]></description>
			<content:encoded><![CDATA[<p>Hoy me ha tocado instalar una <a href="http://debian-amd64.alioth.debian.org/">debian 64bits</a> en un opteron. La verdad es que esta bastante currada, con el nuevo instalador de debian, te lo detecta todo solo y se instala perfectamente. El unico problema que he tenido es que ni el LILO ni el GRUB se han querido instalar, se ve que el tema de arrancar por SATA no le va bien (tenemos 3x120gb SATA en RAID5). Al final gracias al gran invento del chroot, he configurado el LILO, pero el kernel que me instala la debian no trae soporte para la controladora SATA :?, pero tampoco ha habido demasiado problema, chroot, wget nuevo kernel, recompilar, reconfigurar lilo y reboot. La verdad es que va super fino y no me esperaba que estubiesen ya tantos paquetes portados.</p>
]]></content:encoded>
			<wfw:commentRss>http://p0l0.binware.org/index.php/2005/03/08/debian-64bits/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

