<?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>Vantage Point of Queens &#187; Server Admin</title>
	<atom:link href="http://blog.nydd.org/topic/tech/server-admin/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.nydd.org</link>
	<description>Art, Hack and Rock'n Roll</description>
	<lastBuildDate>Wed, 16 Jun 2010 13:59:49 +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>gitosis をインストール</title>
		<link>http://blog.nydd.org/2010/01/gitosis%e3%82%92%e3%82%a4%e3%83%b3%e3%82%b9%e3%83%88%e3%83%bc%e3%83%ab/</link>
		<comments>http://blog.nydd.org/2010/01/gitosis%e3%82%92%e3%82%a4%e3%83%b3%e3%82%b9%e3%83%88%e3%83%bc%e3%83%ab/#comments</comments>
		<pubDate>Mon, 18 Jan 2010 06:00:33 +0000</pubDate>
		<dc:creator>beatak</dc:creator>
				<category><![CDATA[Server Admin]]></category>
		<category><![CDATA[Tech]]></category>

		<guid isPermaLink="false">http://blog.nydd.org/?p=306</guid>
		<description><![CDATA[				仕事場では昨年から git を使っています。svn と比べていろんな利点があるとは思いますが、スピードが僕には捨てがたいです。というわけで自分用の git サーバーを立てたいのですが、管理を全て、というのはちょっと面倒くさいし… そこで gitosis という管理ツール群を見つけました。
				日本語で書かれたものとして openbooth さんの gitosis &#8211; Git リポジトリ群の管理とアクセス制御 vol.1が非常によく纏まっています。僕は Install (Set Up) Git and Gitosis on Ubuntu を参考にしました。
				解説は上に上げたページを参考にしてもらうとして僕が少しハマったところを解説します。
				
				sudo python setup.py install は gitosis-init, gitosis-run-hook, gitosis-serve を /usr/bin 以下にセットアップする
				gitosis-init は実行したユーザのホームディレクトリに repositories ディレクトリなどを勝手に作ってくれる
				sudo chmod u+x /var/git/repositories/gitosis-admin.git/hooks/post-update は絶対にする。逆に他の hooks script は +x である必要はない
				クライアント側でする最初のタスクは、git 開発の手順通り、git clone ssh://GIT_USER_NAME@YOUR.HOST.NAME/gitosis-admin.git git clone の url がわからなかったらマニュアル参照: [...]]]></description>
			<content:encoded><![CDATA[				<p>仕事場では昨年から git を使っています。svn と比べていろんな利点があるとは思いますが、スピードが僕には捨てがたいです。というわけで自分用の git サーバーを立てたいのですが、管理を全て、というのはちょっと面倒くさいし… そこで gitosis という管理ツール群を見つけました。</p>
				<p>日本語で書かれたものとして openbooth さんの gitosis &#8211; <a href="http://openbooth.org/archives/65.html">Git リポジトリ群の管理とアクセス制御 vol.1</a>が非常によく纏まっています。僕は <a href="http://blog.agdunn.net/?p=277">Install (Set Up) Git and Gitosis on Ubuntu</a> を参考にしました。</p>
				<p>解説は上に上げたページを参考にしてもらうとして僕が少しハマったところを解説します。</p>
				<ul>
				<li><code class="prettyprint">sudo python setup.py install</code> は <code class="prettyprint">gitosis-init, gitosis-run-hook, gitosis-serve</code> を /usr/bin 以下にセットアップする</li>
				<li><code class="prettyprint">gitosis-init</code> は実行したユーザのホームディレクトリに repositories ディレクトリなどを勝手に作ってくれる</li>
				<li><code class="prettyprint">sudo chmod u+x /var/git/repositories/gitosis-admin.git/hooks/post-update</code> は絶対にする。逆に他の hooks script は +x である必要はない</li>
				<li>クライアント側でする最初のタスクは、git 開発の手順通り、<code class="prettyprint">git clone ssh://GIT_USER_NAME@YOUR.HOST.NAME/gitosis-admin.git</code> git clone の url がわからなかったらマニュアル参照: <a href="http://www.kernel.org/pub/software/scm/git/docs/git-clone.html">git-clone(1)</a> 僕は ssh に 22 を使っていないので、<code class="prettyprint">git clone ssh://GIT_USER_NAME@YOUR.HOST.NAME:PORT_NUM/gitosis-admin.git</code> のようになりました。</li>
				<li>gitosis.conf を編集して、新しいレポジトリを作る時、writable にするのを忘れない。そして keyfiles に ユーザの ssh public key を追加するのを忘れない。</li>
				<li>一番最初に 新しい repository を追加する前に、僕のように ssh:22 で無い人は、client 側の ssh_config に、
				<pre><code class="prettyprint">Host YOUR.HOST.NAME
Port PORT
IdentityFile ~/.ssh/id_rsa
Protocol 2</code></pre>
				<p>を追加しておく必要あり。そうしないと <code>git remote add origin GIT_USER_NAME@YOUR.HOST.NAME:PROJECT_NAME.git</code> が実行できない</li>
				</ul>
				<p>あと、エラーがでて git push が成功しなくても、サーバにログインして fix しちゃダメだよね。このツールはサーバに git を使って git を管理できるってのが売りだし。おそらく次回は commit hook の設定の仕方かな？</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.nydd.org/2010/01/gitosis%e3%82%92%e3%82%a4%e3%83%b3%e3%82%b9%e3%83%88%e3%83%bc%e3%83%ab/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Update SSL Certificate</title>
		<link>http://blog.nydd.org/2010/01/update-ssl-certificate/</link>
		<comments>http://blog.nydd.org/2010/01/update-ssl-certificate/#comments</comments>
		<pubDate>Sat, 02 Jan 2010 04:45:33 +0000</pubDate>
		<dc:creator>beatak</dc:creator>
				<category><![CDATA[Server Admin]]></category>

		<guid isPermaLink="false">http://blog.nydd.org/?p=302</guid>
		<description><![CDATA[				あけましておめでとうございます。本年もどうぞよろしく。2009 年のまとめもせずに、本題に入ります。
				僕は別のサイトで、CAcert.org を利用して、いわゆるオレオレ証明書ではない、https 通信を実現しています。利用者に root 証明書のインストールを要求するので、本質的にオレオレと変わりない、という批判は受け入れます。が、これ以降 CAcert がどう化けるかわかりませんし、証明書作成のプロセスの勉強にもなります。
				なお本記事の多くは以下のページに依りました。
				CACert.orgで無料のSSLサーバを動かすメモ [FreeBSD](fkimura.com)
				今回は更新なので、domain の登録は済んでいるものとします。Domain の登録に必要なのは、メールアドレスだけです。
				作業手順
				
				サーバ秘密鍵作成の作成 openssl genrsa -rand /var/log/messages -des3 -out /path/to/example.key 1024 54002 semi-random bytes loadedパスワードは後で使うことは、あまり、ない。
				証明書申請データの作成 openssl req -new -key /path/to/example.key -out /usr/local/etc/apache2/ssl.key/example.jp.csrここで唯一のハマりどころはCommon Name [CN] が、登録済みの domain と一致する必要がある、ということ。
				証明書申請データを提出する
				(1)で作成したキーのパスフレーズを解除する
				今回作成した 4 ファイルの permission を全て 600 にする
				httpd.conf をアップデート
				
				fkimura.com に書いてあるそのままなんですが、あまりやらない作業はなんとなくやりたくない、という心理障壁になります。blog に書いておけば、また半年後やる時に、思い返せるでしょう。
				というわけで本年もどうぞよろしく。
]]></description>
			<content:encoded><![CDATA[				<p>あけましておめでとうございます。本年もどうぞよろしく。2009 年のまとめもせずに、本題に入ります。</p>
				<p>僕は別のサイトで、<a href="https://www.cacert.org/">CAcert.org</a> を利用して、いわゆるオレオレ証明書ではない、https 通信を実現しています。利用者に root 証明書のインストールを要求するので、本質的にオレオレと変わりない、という批判は受け入れます。が、これ以降 CAcert がどう化けるかわかりませんし、証明書作成のプロセスの勉強にもなります。</p>
				<p>なお本記事の多くは以下のページに依りました。</p>
				<p><a href="http://freebsd.fkimura.com/cacert-a0.html">CACert.orgで無料のSSLサーバを動かすメモ [FreeBSD](fkimura.com)</a></p>
				<p>今回は更新なので、domain の登録は済んでいるものとします。Domain の登録に必要なのは、メールアドレスだけです。</p>
				<h4>作業手順</h4>
				<ol>
				<li>サーバ秘密鍵作成の作成 <br /><code>openssl genrsa -rand /var/log/messages -des3 -out /path/to/example.key 1024 54002 semi-random bytes loaded</code><br />パスワードは後で使うことは、あまり、ない。</li>
				<li>証明書申請データの作成 <br /><code>openssl req -new -key /path/to/example.key -out /usr/local/etc/apache2/ssl.key/example.jp.csr</code><br />ここで唯一のハマりどころはCommon Name [CN] が、登録済みの domain と一致する必要がある、ということ。</li>
				<li>証明書申請データを提出する</li>
				<li>(1)で作成したキーのパスフレーズを解除する</li>
				<li>今回作成した 4 ファイルの permission を全て 600 にする</li>
				<li>httpd.conf をアップデート</li>
				</ol>
				<p>fkimura.com に書いてあるそのままなんですが、あまりやらない作業はなんとなくやりたくない、という心理障壁になります。blog に書いておけば、また半年後やる時に、思い返せるでしょう。</p>
				<p>というわけで本年もどうぞよろしく。</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.nydd.org/2010/01/update-ssl-certificate/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
