break-in
author Paul Crowley <paul@lshift.net>
Wed, 28 May 2008 18:14:15 +0100
changeset 31 d54720d47ca2
child 32 4059dbe9f26a
permissions -rwxr-xr-x
start to move towards things living where they should and new break-in system. Big change.

#!/bin/sh

set -e

REPO=~hg/repos/hgadmin
sudo -u hg -H hg -q -R "$REPO" update null
sudo -u hg mkdir $REPO/keys
cp $1 $REPO/keys/root
cd $REPO
echo "init user=root" > hg-ssh-access.conf
sudo -u hg -H /usr/local/lib/hg-admin-tools/refresh-auth ~/.ssh/authorized_keys /etc/hg-admin-tools/hg-ssh-wrapper