GAE has "magic" around sending emails.  Someone extended the Mail()
class in web2py to work with this magic.  basically you don't need
passwords to send from a GAE application if you are sending mail as
one of the administrators.   your configuration for mail should look
like:

mail=Mail()                                  # mailer
mail.settings.server='gae'    # your SMTP server
mail.settings.sender='[email protected]'         # your email
auth.settings.mailer=mail                    # for user email
verification

and it will send mail.  no password required.  if a user is logged in
via google accounts you can also send mail "from" that user.  i'm
using that for a support form - it sends mail to my support address
from the logged in user.  no passwords, it just works.  pretty nifty,
eh?

good luck,

cfh

On May 23, 9:51 am, mattynoce <[email protected]> wrote:
> hi, i have a question about sending emails. i'm running my program on
> google app engine, and due to google's rules i need to have an
> administrator as the "from" for all my emails. so i created an
> account, let's call it "[email protected]," figuring that would
> be the "from" for all my emails for now.
>
> to send emails, [email protected] needs to be an administrator
> of the application on gae, so i did that. but i'm in a situation where
> i'm sharing code with other developers i need to work with but don't
> want to give them admin access.
>
> in db.py, i have the following lines:
> mail.settings.sender='[email protected]'
> mail.settings.login='[email protected]:testPassword'
>
> but by giving web2py my email password, i'm actually giving other
> developers full administrative access to my application on gae.
>
> i recognize this isn't a web2py "problem," but it's an issue i need to
> solve. does anyone have any ideas of how to get around this?
>
> thanks,
>
> matt

Reply via email to