<?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>Objective-T</title>
	<atom:link href="http://objective-t.de/feed/" rel="self" type="application/rss+xml" />
	<link>http://objective-t.de</link>
	<description>Thomas Jachmann</description>
	<lastBuildDate>Mon, 29 Jun 2009 15:01:00 +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>Out of Office</title>
		<link>http://objective-t.de/2009/06/05/out-of-office/</link>
		<comments>http://objective-t.de/2009/06/05/out-of-office/#comments</comments>
		<pubDate>Fri, 05 Jun 2009 10:21:24 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[career]]></category>

		<guid isPermaLink="false">http://objective-t.de/?p=15</guid>
		<description><![CDATA[Vor etwas mehr als sieben Jahren habe ich zusammen mit drei Projektkollegen mindmatters gegründet. Ich bin extra dafür nach Hamburg gezogen, habe meine bisherige Anstellung aufgegeben, es war ein großer Sprung. Die Firma hat speziell in den letzten Jahren eine erstaunliche Entwicklung vollzogen. Wir haben über die Jahre sehr viele spannende Projekte realisiert, und ich habe immens [...]]]></description>
			<content:encoded><![CDATA[<p>Vor etwas mehr als sieben Jahren habe ich zusammen mit drei Projektkollegen <a href="http://mindmatters.de">mindmatters</a> gegründet. Ich bin extra dafür nach Hamburg gezogen, habe meine bisherige Anstellung aufgegeben, es war ein großer Sprung. Die Firma hat speziell in den letzten Jahren eine erstaunliche Entwicklung vollzogen. Wir haben über die Jahre sehr viele spannende Projekte realisiert, und ich habe immens viel Erfahrung sammeln und vieles lernen können.</p>
<p>Aber Dinge verändern sich mit der Zeit, Ziele verschieben sich. Ende letzten Jahres haben wir begonnen, meinen Ausstieg aus der Firma zu planen. Seit Anfang des Jahres bin ich schon nicht mehr im operativen Einsatz, nun scheide ich auch als Gesellschafter aus. Ich werde von nun an als freiberuflicher Software-Entwickler tätig sein und nebenbei eigene Ideen und Projekte vorantreiben. Das ist wieder ein großer Sprung, wenn auch nicht ganz so groß wie der in 2001, und ich freue mich sehr auf die nächsten Monate.</p>
<p>Vielen Dank an mindmatters für die letzten Jahre. Auch dafür, dass ich jetzt in Hamburg bin. Vielen Dank an alle Kollegen für die großartige Zusammenarbeit, die Anregungen, die Denkanstöße und die tolle Zeit in unserem Großraum-/Kicker-/Musik-Büro, glücklicherweise werde ich wohl <a href="http://www.facebook.com/event.php?eid=108141766339">nicht ganz darauf verzichten</a> müssen. Ich wünsche allen weiterhin viel Erfolg!</p>
]]></content:encoded>
			<wfw:commentRss>http://objective-t.de/2009/06/05/out-of-office/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Using Gitosis on DreamHost</title>
		<link>http://objective-t.de/2009/05/11/using-gitosis-on-dreamhost/</link>
		<comments>http://objective-t.de/2009/05/11/using-gitosis-on-dreamhost/#comments</comments>
		<pubDate>Mon, 11 May 2009 23:08:06 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[tech]]></category>
		<category><![CDATA[admin]]></category>
		<category><![CDATA[dreamhost]]></category>
		<category><![CDATA[git]]></category>
		<category><![CDATA[shared hosting]]></category>

		<guid isPermaLink="false">http://objective-t.de/?p=3</guid>
		<description><![CDATA[In order to use gitosis on your DreamHost account, you'll need to create a dedicated user, install gitosis and start configuring gitosis/pushing to your repositories.]]></description>
			<content:encoded><![CDATA[<p>In order to use gitosis on your DreamHost account, you&#8217;ll need to create a dedicated user, install gitosis and start configuring gitosis/pushing to your repositories.</p>
<h3>Create User</h3>
<p>It is best to use this user for gitosis only, since it modifies .ssh/authorized_keys and you might not be able to access the account using ssh when using pubkey authentication since it restricts shell access to gitosis-serve only. So if you need to do something on the account later and you&#8217;re blocked to log in, you still can ssh into the system using another user and su into your gitosis user. Create a user using the <a href="https://panel.dreamhost.com/index.cgi?tree=users.users&amp;">web panel</a>, then login in using that user.</p>
<h3>Prepare site-packages Installation</h3>
<p>Gitosis uses python&#8217;s setuptools for installation. This will install to the system&#8217;s site-packages directory (usually /usr/lib/python2.4/site-packages/). In a shared hosting environment, you don&#8217;t have write access to this directory. First, create a local directory structure in ~/opt/ where everything will be installed to and then modify some environment variables for these directories to be used.</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;"># create directory structure</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>bin ~<span style="color: #000000; font-weight: bold;">/</span>opt<span style="color: #000000; font-weight: bold;">/</span>lib<span style="color: #000000; font-weight: bold;">/</span>python2.4<span style="color: #000000; font-weight: bold;">/</span>site-packages
&nbsp;
<span style="color: #666666; font-style: italic;"># adjust environment variables</span>
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;export PATH=<span style="color: #007800;">$HOME</span>/opt/bin:<span style="color: #007800;">$PATH</span>&quot;</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> ~<span style="color: #000000; font-weight: bold;">/</span>.bashrc
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;export PYTHONPATH=<span style="color: #007800;">$HOME</span>/opt/lib/python2.4/site-packages&quot;</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> ~<span style="color: #000000; font-weight: bold;">/</span>.bashrc
&nbsp;
<span style="color: #666666; font-style: italic;"># load changes</span>
<span style="color: #7a0874; font-weight: bold;">source</span> ~<span style="color: #000000; font-weight: bold;">/</span>.bashrc</pre></div></div>

<h3>Install Git</h3>
<p>If the version of git (1.5.6.5 at time of writing) is sufficient for you, you don&#8217;t have to install a current git version. If you need to, see the references below for instructions on how to do it.</p>
<h3>Install Gitosis</h3>
<p>While installing gitosis, you need to tell the installer to install it to your local directory structure.</p>
<p>In order to setup gitosis, you&#8217;ll need your personal pubkey (in this example, it is assumed that you transferred the file id_dsa.pub &#8211; or however your pubkey&#8217;s named &#8211; to the gitosis user&#8217;s home folder). This will be used to authorize the initial admin user access.</p>
<p>In order for the administrative functions of gitosis to function, the post-update hook needs to be executable. This will export .gitosis.conf and adjust .ssh/authorized_keys so that the configured users have access to the system.</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;"># download gitosis</span>
git clone git:<span style="color: #000000; font-weight: bold;">//</span>eagain.net<span style="color: #000000; font-weight: bold;">/</span>gitosis.git
&nbsp;
<span style="color: #666666; font-style: italic;"># install gitosis</span>
<span style="color: #7a0874; font-weight: bold;">cd</span> gitosis
python setup.py <span style="color: #c20cb9; font-weight: bold;">install</span> <span style="color: #660033;">--prefix</span>=<span style="color: #007800;">$HOME</span><span style="color: #000000; font-weight: bold;">/</span>opt
&nbsp;
<span style="color: #666666; font-style: italic;"># initial setup</span>
gitosis-init <span style="color: #000000; font-weight: bold;">&lt;</span> ~<span style="color: #000000; font-weight: bold;">/</span>id_dsa.pub
&nbsp;
<span style="color: #666666; font-style: italic;"># adjust access rights</span>
<span style="color: #c20cb9; font-weight: bold;">chmod</span> u+x ~<span style="color: #000000; font-weight: bold;">/</span>repositories<span style="color: #000000; font-weight: bold;">/</span>gitosis-admin.git<span style="color: #000000; font-weight: bold;">/</span>hooks<span style="color: #000000; font-weight: bold;">/</span>post-update
&nbsp;
<span style="color: #666666; font-style: italic;"># remove installation files</span>
<span style="color: #7a0874; font-weight: bold;">cd</span> ..
<span style="color: #c20cb9; font-weight: bold;">rm</span> <span style="color: #660033;">-rf</span> gitosis</pre></div></div>

<p><strong>This is all you&#8217;ve got to do on the server.</strong></p>
<h3>Configure Gitosis</h3>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;"># download gitosis' configuration repository</span>
git clone <span style="color: #000000; font-weight: bold;">&lt;</span>youruser<span style="color: #000000; font-weight: bold;">&gt;@&lt;</span>yourserver<span style="color: #000000; font-weight: bold;">&gt;</span>:gitosis-admin.git
<span style="color: #7a0874; font-weight: bold;">cd</span> gitosis-admin
&nbsp;
<span style="color: #666666; font-style: italic;"># add pubkeys into keydir and edit gitosis.conf</span>
<span style="color: #666666; font-style: italic;"># for example add your pubkey and add it to a new group devs</span>
<span style="color: #666666; font-style: italic;"># that has write access to a new project repository</span>
<span style="color: #c20cb9; font-weight: bold;">cp</span> ~<span style="color: #000000; font-weight: bold;">/</span>.ssh<span style="color: #000000; font-weight: bold;">/</span>id_dsa.pub keydir<span style="color: #000000; font-weight: bold;">/</span>thomas.pub
<span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;[group devs]
writable = new_project
members = thomas&quot;</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> gitosis.conf
&nbsp;
<span style="color: #666666; font-style: italic;"># upload changes to server</span>
git add .
git commit <span style="color: #660033;">-m</span> <span style="color: #ff0000;">'configuration changes'</span>
git push</pre></div></div>

<p>Note that the remote repository doesn&#8217;t exist yet. Just push to it in the next step and it will be created automatically.</p>
<h3>Create Repository And Push To Server</h3>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;"># create project</span>
<span style="color: #c20cb9; font-weight: bold;">mkdir</span> new_project
<span style="color: #7a0874; font-weight: bold;">cd</span> new_project
&nbsp;
<span style="color: #666666; font-style: italic;"># init local git repository</span>
git init
&nbsp;
<span style="color: #666666; font-style: italic;"># do something, add and commit</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># add remote repository and add tracking</span>
git remote add origin <span style="color: #000000; font-weight: bold;">&lt;</span>youruser<span style="color: #000000; font-weight: bold;">&gt;@&lt;</span>yourserver<span style="color: #000000; font-weight: bold;">&gt;</span>:new_project.git
git config branch.master.remote origin
git config branch.master.merge refs<span style="color: #000000; font-weight: bold;">/</span>heads<span style="color: #000000; font-weight: bold;">/</span>master
<span style="color: #666666; font-style: italic;"># next line needed for git &gt; 1.6.3 to avoid warning messages</span>
git config push.default current
&nbsp;
<span style="color: #666666; font-style: italic;"># push to remote repository</span>
git push origin master</pre></div></div>

<p>From now  on, you can use git pull/git push since tracking has been established.</p>
<h3>References</h3>
<ul>
<li><a href="http://scie.nti.st/2007/11/14/hosting-git-repositories-the-easy-and-secure-way">http://scie.nti.st/2007/11/14/hosting-git-repositories-the-easy-and-secure-way</a></li>
<li><a href="http://openmonkey.com/articles/2009/02/installing-gitosis-on-dreamhost">http://openmonkey.com/articles/2009/02/installing-gitosis-on-dreamhost</a></li>
<li><a href="http://thelucid.com/2008/12/02/git-setting-up-a-remote-repository-and-doing-an-initial-push">http://thelucid.com/2008/12/02/git-setting-up-a-remote-repository-and-doing-an-initial-push</a></li>
<li><a href="http://pivotallabs.com/users/alex/blog/articles/883-git-config-push-default-matching">http://pivotallabs.com/users/alex/blog/articles/883-git-config-push-default-matching</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://objective-t.de/2009/05/11/using-gitosis-on-dreamhost/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

