src/init/conf/refresh-auth
author Paul Crowley <paul@lshift.net>
Fri, 20 Feb 2009 17:34:30 +0000
changeset 59 f96de2d99f00
parent 50 77d97aa18f29
child 73 5d81ec164e5d
permissions -rwxr-xr-x
give logging module a more specific name
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
39
f5055ce263c7 New system. No breaking in, just putting files in /etc/mercurial-server
Paul Crowley <paul@lshift.net>
parents:
diff changeset
     1
#!/bin/sh
50
77d97aa18f29 update dates and copyright notices
Paul Crowley <paul@lshift.net>
parents: 39
diff changeset
     2
# Copyright 2008-2009 LShift Ltd
39
f5055ce263c7 New system. No breaking in, just putting files in /etc/mercurial-server
Paul Crowley <paul@lshift.net>
parents:
diff changeset
     3
f5055ce263c7 New system. No breaking in, just putting files in /etc/mercurial-server
Paul Crowley <paul@lshift.net>
parents:
diff changeset
     4
# This file should live in /etc/mercurial-server.
f5055ce263c7 New system. No breaking in, just putting files in /etc/mercurial-server
Paul Crowley <paul@lshift.net>
parents:
diff changeset
     5
# If your repository is laid out differently you may need to modify
f5055ce263c7 New system. No breaking in, just putting files in /etc/mercurial-server
Paul Crowley <paul@lshift.net>
parents:
diff changeset
     6
# this file.
f5055ce263c7 New system. No breaking in, just putting files in /etc/mercurial-server
Paul Crowley <paul@lshift.net>
parents:
diff changeset
     7
f5055ce263c7 New system. No breaking in, just putting files in /etc/mercurial-server
Paul Crowley <paul@lshift.net>
parents:
diff changeset
     8
set -e
f5055ce263c7 New system. No breaking in, just putting files in /etc/mercurial-server
Paul Crowley <paul@lshift.net>
parents:
diff changeset
     9
f5055ce263c7 New system. No breaking in, just putting files in /etc/mercurial-server
Paul Crowley <paul@lshift.net>
parents:
diff changeset
    10
if [ `whoami` != 'hg' ] ; then
f5055ce263c7 New system. No breaking in, just putting files in /etc/mercurial-server
Paul Crowley <paul@lshift.net>
parents:
diff changeset
    11
    echo "Must be run as hg user"
f5055ce263c7 New system. No breaking in, just putting files in /etc/mercurial-server
Paul Crowley <paul@lshift.net>
parents:
diff changeset
    12
    return -1
f5055ce263c7 New system. No breaking in, just putting files in /etc/mercurial-server
Paul Crowley <paul@lshift.net>
parents:
diff changeset
    13
else
f5055ce263c7 New system. No breaking in, just putting files in /etc/mercurial-server
Paul Crowley <paul@lshift.net>
parents:
diff changeset
    14
    /usr/local/lib/mercurial-server/do-refresh-auth \
f5055ce263c7 New system. No breaking in, just putting files in /etc/mercurial-server
Paul Crowley <paul@lshift.net>
parents:
diff changeset
    15
        ~hg/.ssh/authorized_keys \
f5055ce263c7 New system. No breaking in, just putting files in /etc/mercurial-server
Paul Crowley <paul@lshift.net>
parents:
diff changeset
    16
        /etc/mercurial-server/hg-ssh-wrapper \
f5055ce263c7 New system. No breaking in, just putting files in /etc/mercurial-server
Paul Crowley <paul@lshift.net>
parents:
diff changeset
    17
        /etc/mercurial-server/keys \
f5055ce263c7 New system. No breaking in, just putting files in /etc/mercurial-server
Paul Crowley <paul@lshift.net>
parents:
diff changeset
    18
        ~hg/repos/hgadmin/keys
f5055ce263c7 New system. No breaking in, just putting files in /etc/mercurial-server
Paul Crowley <paul@lshift.net>
parents:
diff changeset
    19
fi