[buildd-tools-devel] Bug#625205: Bug#625205: is there a way to automatically start services inside an schroot session?

Roger Leigh rleigh at codelibre.net
Mon May 2 17:09:22 UTC 2011


On Mon, May 02, 2011 at 03:48:52PM +0200, Marc Haber wrote:
> I would like to automatically start an schroot session on bootup, and
> start two services inside that schroot session. I am wondering whether
> schroot does have the mechanisms to do this automatically, or whether
> I would have to take my own provisions to have the services started.
[...]
> but I am wondering whether schroot has possibilities to do this any
> easier, for example with a script run from script-config.
> 
> What is the correct schroot way to do things?

We currently don't make any provision for doing this--you would
need to do something as in the example you gave.  However, I would
certainly not oppose having some generic method for starting and
stopping services inside schroot chroots which would allow one to
specify a chroot to begin a session with and then actions to
start and stop services.  If it was limited to init scripts only
then this would be very simple to do; we would just need to
record the session ID plus the services started in /var/run in
order to reverse the procedure.  If limited to services, we could
create a directory e.g. /etc/schroot/autorun and have files in
there defining which services to run in which chroot, e.g.

[unstable]
  postfix
  postgresql-9.0

[unstable]
  postgresql-8.3

[stable]
  apache

as a simple example.  Any thought on what information is needed
would be very useful.


Regards,
Roger

-- 
  .''`.  Roger Leigh
 : :' :  Debian GNU/Linux             http://people.debian.org/~rleigh/
 `. `'   Printing on GNU/Linux?       http://gutenprint.sourceforge.net/
   `-    GPG Public Key: 0x25BFB848   Please GPG sign your mail.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://lists.alioth.debian.org/pipermail/buildd-tools-devel/attachments/20110502/e56e8feb/attachment.pgp>


More information about the Buildd-tools-devel mailing list