cobblerのdebian用パッケージのコンパイル

https://fedorahosted.org/cobbler/wiki/DownloadInstructions
ここに書いてある通りなんだけど、認証プロキシの下だったので、pdebuildのときにパッケージが取ってこれなくて若干工夫が必要だった。

解決方法としては、apt-cacherを入れて、プロキシの認証はapt-cacherにお任せした。

apt-cacherの環境づくり

sudo aptitude install apt-cacher
sudo vim /etc/apt-cacher/apt-cacher.conf

  http_proxy=proxy_host:proxy_port
  use_proxy=1
  http_proxy_auth=id:password
  use_proxy_auth=1

sudo vim /etc/default/apt-cacher

  AUTOSTART=1

sudo /etc/init.d/apt-cacher start

0.0.0.0:3142 でapt-cacherが動きます。

pbuilderの環境づくり

sudo aptitude install pbuilder
sudo vim /etc/pbuilderrc

  MIRRORSITE=http://host_ip:3142/ftp.jp.debian.org/debian/

sudo pbuilder --create --distribution wheezy  --http-proxy http://proxy_host:proxy_port/

cobbler のコンパイル

git clone git://git.fedorahosted.org/cobbler
sudo pdebuild
dpkg -i /var/cache/pbuilder/result/cobbler_1.5.0-1_all.deb

ちなみに、koanはcobblerサーバがxmlrpcを127.0.0.1:25151でlistenしていて、外から叩けなかった。
apacheからproxyして、koan --port=80 で叩いた。