AuScope / ckan-docker

Scripts and images to run CKAN using Docker Compose
0 stars 2 forks source link

Email notification upon data submission #166

Closed kitchenprinzessin3880 closed 5 months ago

kitchenprinzessin3880 commented 6 months ago

@stuartwoodman is there a way to integrate email function with data submission? e.g. email sent to auscope.doi@csiro.au when the user clicks the submit button?

stuartwoodman commented 6 months ago

Should be doable, I'll take a look.

kitchenprinzessin3880 commented 6 months ago

@stuartwoodman received the data submission email

Screenshot 2024-05-14 at 12 31 06 PM

I think we need to send an email to the data depositor too:

Dear Depositor,

Thank you for submitting the following data: Dataset title: Link to dataset:

Our curator will review and contact you to publish your submission. Thank you.

Kind Regards, AuScope Data Repository

stuartwoodman commented 6 months ago

Easy enough.

Is repository-dev@data.auscope.org.au an actual email address? That's set in the config, easy to switch to auscope.doi if we want to, but not sure if this was intentional. Production has repository@data.suscope.org.au.

kitchenprinzessin3880 commented 6 months ago

Easy enough.

Is repository-dev@data.auscope.org.au an actual email address? That's set in the config, easy to switch to auscope.doi if we want to, but not sure if this was intentional. Production has repository@data.suscope.org.au.

it should auscope.doi@csiro.au for both dev and prod instances

kitchenprinzessin3880 commented 6 months ago

Easy enough.

Is repository-dev@data.auscope.org.au an actual email address? That's set in the config, easy to switch to auscope.doi if we want to, but not sure if this was intentional. Production has repository@data.suscope.org.au.

@vjf which email is associated with AWS SMTP?

stuartwoodman commented 6 months ago

@vjf which email is associated with AWS SMTP?

I didn't even think about this having an effect on that, but that was the setting I changed: CKAN_SMTP_MAIL_FROM

Maybe we need to change it back until we can register (or whatever's required) the proper email?

kitchenprinzessin3880 commented 6 months ago

tested data submission via gmail. both notifications received, see below

Screenshot 2024-05-15 at 5 59 27 PM Screenshot 2024-05-15 at 5 59 47 PM

@stuartwoodman Why wasn't the email notifications work before?

stuartwoodman commented 6 months ago

@stuartwoodman Why wasn't the email notifications work before?

Originally it was an issue with needing to come out of AWS's sandbox. When that happened and I implemented notifications it was working, but I broke it when I changed the FROM email addresses to doi.auscope.csiro.au to match the main site email. The issue was AWS had been configured to use the repository(-dev) emails. Unfortunately we can't use a *.csiro.au email as the email won't be coming from CSIRO, hence the auscope ones.

Not so much an issue for the admin emails, but for the user perhaps we need to add a link to the Data Repo contact form (if it is a form and not just an email link), or a "mailto" email link ourselves that wil open a draft email to the doi address.

Perhaps we could use a "do-not-respond@data.auscope.org.au" email just to make it clear that they should not respond to that email. We'd still need to clear that with AWS assuming specific addresses were registered rather than the domain.

kitchenprinzessin3880 commented 6 months ago

Perhaps we could use a "do-not-respond@data.auscope.org.au" email just to make it clear that they should not respond to that email. We'd still need to clear that with AWS assuming specific addresses were registered rather than the domain.

@vjf any thought on this?

kitchenprinzessin3880 commented 5 months ago

I am going to close this issue as Sam is exploring other mailbox alternative - https://github.com/AuScope/ckan-docker/issues/185