Using the SmartServer of v0.15 with xinetd

Aaron Bentley aaron.bentley at utoronto.ca
Thu Apr 12 17:46:49 BST 2007


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Thomas Ackermann wrote:
> John Arbash Meinel schrieb:
>> You might consider writing a bash wrapper script like:
>>
>> bzr_as_bzruser.sh:
>>
>> #!/bin/sh
>> su - bzruser -c "bzr "$*""
>>
>
> Oh John :)
>
> You made my day :)
>
> localhost:/etc/xinetd.d # cat bzr
> service bzr
> {
>        server_args     = serve --inet --directory=/home/archive/bzr
>        log_on_success  += DURATION USERID
>        log_on_failure  += USERID
>        nice            = 10
>        disable         = no
>        socket_type     = stream
>        protocol        = tcp
>        wait            = no
>        user            = root
>        server          = /usr/local/bin/run_bzr.sh
>        port            = 22618
> }

So, two alternatives are:

1. invoke su directly:
server          = /sbin/su
server_args     = - bzruser bzr serve --inet\
 --directory=/home/archive/bzr

2. specify HOME directly, using the env parameter

> I think, this should go into the FAQ!

Well, it's a wiki.  Go wild.

Aaron
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFGHmJ50F+nu1YWqI0RAgEDAJ9F8aQyZA8w4gmiCPGQWmGYDRq0WQCdGF0e
eFmWJ8ghHbgaTVHXoYGcBIU=
=D1g7
-----END PGP SIGNATURE-----



More information about the bazaar mailing list