Most of Launchpad's email is sent using immediate delivery, which uses
`smtplib` directly; but some, such as email sent by garbo jobs, instead
queues it up until the end of the transaction. The latter mode wasn't
configured properly on production, so outgoing email ended up in a
default "stub" mailer which sent everything to root@localhost. Add
configuration to send queued production email to localhost:25 as well.
Individual charms must call `configure_email` to install
`mail-configure.zcml` in the appropriate configuration directory, or
remove it if `send_email` is false.
The `ols` layer creates this as a system user since it has no password,
leaving its shell at the default of `/bin/sh`. For a user that's never
used interactively, that's fine. However, at least some deployments
based on this layer will end up being used interactively, especially
`launchpad-admin`, so change the shell to `/bin/bash` so that it's more
pleasant to do so.
Add many missing entries to launchpad-base-lazr.conf
I must have got distracted or something in the middle of writing this
template originally, since there were quite a few entries in
`config.yaml` that this layer was doing nothing with for no good reason.
Add a `configure_cron` function that sets up a crontab from a template.
Launchpad's crontabs generally include a call to `oops-datedir2amqp` to
catch up with publishing OOPSes that were temporarily spooled to disk.
This needs a bit of extra support in building the config dictionary,
since it needs RabbitMQ credentials in a different form.