~mdw
/
mirror-admin
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
f7b14ed
)
bin/run-mirrors: Use sudo to change user.
author
Mark Wooding
<mdw@distorted.org.uk>
Tue, 16 Aug 2011 09:20:56 +0000
(10:20 +0100)
committer
Mark Wooding
<mdw@distorted.org.uk>
Tue, 16 Aug 2011 09:22:29 +0000
(10:22 +0100)
The mirror user's home is elsewhere on vampire, so userv doesn't work as
well.
bin/run-mirrors
patch
|
blob
|
blame
|
history
diff --git
a/bin/run-mirrors
b/bin/run-mirrors
index
1dc0a14
..
1dffeec
100755
(executable)
--- a/
bin/run-mirrors
+++ b/
bin/run-mirrors
@@
-5,7
+5,7
@@
set -e
## Make sure we're running as the right user.
case $(id -un) in
mirror) ;;
## Make sure we're running as the right user.
case $(id -un) in
mirror) ;;
- *) exec
userv -fstdin=/dev/null mirror run
;;
+ *) exec
sudo -umirror "$0" "$@"
;;
esac
## Set up a plausible environment.
esac
## Set up a plausible environment.