mirror of
https://github.com/internetee/registry.git
synced 2025-06-05 20:27:30 +02:00
update mail templates
This commit is contained in:
parent
35f60e53e5
commit
09ba0a2511
10 changed files with 171 additions and 15 deletions
|
@ -108,12 +108,12 @@ class NameserverRecordValidationJob < ApplicationJob
|
||||||
false
|
false
|
||||||
end
|
end
|
||||||
|
|
||||||
def inform_to_tech_contact(domain:, text:)
|
def inform_to_tech_contact(domain:, text: nil)
|
||||||
ContactNotification.notify_tech_contact(domain: domain, text: text)
|
ContactNotification.notify_tech_contact(domain: domain, reason: 'nameserver')
|
||||||
end
|
end
|
||||||
|
|
||||||
def inform_to_registrar(text:, nameserver:)
|
def inform_to_registrar(nameserver:, text: nil)
|
||||||
# text = "DNSKEYS for #{domain.name} are invalid!"
|
text = "Host record #{nameserver.hostname} of a domain #{nameserver.domain} is invalid. Please fix or contact the registrant."
|
||||||
logger.info text
|
logger.info text
|
||||||
ContactNotification.notify_registrar(domain: nameserver.domain, text: text)
|
ContactNotification.notify_registrar(domain: nameserver.domain, text: text)
|
||||||
end
|
end
|
||||||
|
|
|
@ -46,10 +46,10 @@ class ValidateDnssecJob < ApplicationJob
|
||||||
|
|
||||||
return if flag
|
return if flag
|
||||||
|
|
||||||
text = "DNSKEYS for #{domain.name} are invalid!"
|
text = "DNSKEY record of a domain #{domain.name} is invalid. Please fix or contact the registrant."
|
||||||
logger.info text
|
logger.info text
|
||||||
ContactNotification.notify_registrar(domain: domain, text: text)
|
ContactNotification.notify_registrar(domain: domain, text: text)
|
||||||
ContactNotification.notify_tech_contact(domain: domain, text: text)
|
ContactNotification.notify_tech_contact(domain: domain, reason: 'dnssec')
|
||||||
end
|
end
|
||||||
|
|
||||||
def validate(hostname:, domain:, type: 'DNSKEY', klass: 'IN')
|
def validate(hostname:, domain:, type: 'DNSKEY', klass: 'IN')
|
||||||
|
|
|
@ -1,11 +1,20 @@
|
||||||
class ContactInformMailer < ApplicationMailer
|
class ContactInformMailer < ApplicationMailer
|
||||||
helper_method :address_processing
|
helper_method :address_processing
|
||||||
|
|
||||||
def notify(contact:, domain:, subject:)
|
def notify_dnssec(contact:, domain:)
|
||||||
@contact = contact
|
@contact = contact
|
||||||
@subject = subject
|
|
||||||
@domain = domain
|
@domain = domain
|
||||||
|
|
||||||
|
subject = "Domeeni #{@domain.name} DNSSEC kirjed ei ole korrektsed / The DNSKEY records of the domain #{@domain.name} are invalid"
|
||||||
|
|
||||||
|
mail(to: contact.email, subject: subject)
|
||||||
|
end
|
||||||
|
|
||||||
|
def notify_nameserver(contact:, domain:)
|
||||||
|
@contact = contact
|
||||||
|
@domain = domain
|
||||||
|
|
||||||
|
subject = "Domeeni #{@domain.name} nimeserveri kirjed ei ole korrektsed / The host records of the domain #{@domain.name} are invalid"
|
||||||
mail(to: contact.email, subject: subject)
|
mail(to: contact.email, subject: subject)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -5,12 +5,20 @@ module ContactNotification
|
||||||
domain.registrar.notifications.create(text: text)
|
domain.registrar.notifications.create(text: text)
|
||||||
end
|
end
|
||||||
|
|
||||||
def notify_tech_contact(domain:, text:)
|
def notify_tech_contact(domain:, reason: nil)
|
||||||
# text = "DNSKEYS for #{domain.name} are invalid!"
|
case reason
|
||||||
domain.tech_contacts.each do |tech|
|
when 'dnssec'
|
||||||
contact = Contact.find(tech.id)
|
domain.tech_contacts.each do |tech|
|
||||||
|
contact = Contact.find(tech.id)
|
||||||
|
|
||||||
ContactInformMailer.notify(contact: contact, domain: domain, subject: text).deliver_now
|
ContactInformMailer.notify_dnssec(contact: contact, domain: domain).deliver_now
|
||||||
|
end
|
||||||
|
when 'nameserver'
|
||||||
|
domain.tech_contacts.each do |tech|
|
||||||
|
contact = Contact.find(tech.id)
|
||||||
|
|
||||||
|
ContactInformMailer.notify_nameserver(contact: contact, domain: domain).deliver_now
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -1 +0,0 @@
|
||||||
<p>DNSKEYS for <%= @domain.name %> are invalid!</p>
|
|
|
@ -1 +0,0 @@
|
||||||
<p>DNSKEYS for <%= @domain.name %> are invalid!</p>
|
|
|
@ -0,0 +1,40 @@
|
||||||
|
<h2>Lugupeetud domeeni <%= @domain.name %> tehniline kontakt,</h2>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
Eesti Interneti Sihtasutusele (EIS) juhib tähelepanu, et domeeni <%= @domain.name %> DNSKEY kirjed on puudulikud ning domeeniga seotud teenuse ei pruugi korrektselt toimida.
|
||||||
|
</p>
|
||||||
|
<p>
|
||||||
|
Andmete parandamiseks vaadake palun üle domeeni nimeserverite seaditused või pöörduge palun oma registripidaja <%= @domain.registrar.name %> või nimeserveri teenuse pakkuja poole.</p>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
Lisaküsimuste korral võtke palun ühendust oma registripidajaga:
|
||||||
|
</p>
|
||||||
|
<b><%= @domain.registrar.name %></b><br />
|
||||||
|
<b>Email:</b> <%= @domain.registrar.email %><br />
|
||||||
|
<b>Telefon:</b><%= @domain.registrar.phone %><br />
|
||||||
|
<b>Veebileht:</b><%= @domain.registrar.website %><br />
|
||||||
|
|
||||||
|
Lugupidamisega<br />
|
||||||
|
<b>Eesti Interneti Sihtasutus</b><br />
|
||||||
|
<br/>
|
||||||
|
---
|
||||||
|
<br/>
|
||||||
|
|
||||||
|
<h2>Dear technical contact of <%= @domain.name %> domain,</h2>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
Estonian Internet Foundation points out that the DNSKEY record(s) for the domain <%= @domain.name %> are invalid and the service related to the domain may not work correctly.
|
||||||
|
</p>
|
||||||
|
<p>
|
||||||
|
Please check the DNSKEY records of the domain or contact your registrar <%= @domain.registrar.name%> or your name server service provider to correct this information.
|
||||||
|
</p>
|
||||||
|
<p>
|
||||||
|
Should you have additional questions, please contact your registrar:
|
||||||
|
</p>
|
||||||
|
<b><%= @domain.registrar.name %></b><br />
|
||||||
|
<b>Email:</b> <%= @domain.registrar.email %><br />
|
||||||
|
<b>Phone:</b> <%= @domain.registrar.phone %> <br />
|
||||||
|
<b>Website:</b> <%= @domain.registrar.website %><br />
|
||||||
|
|
||||||
|
Best Regards, <br />
|
||||||
|
<b>Estonian Internet Foundation</b>
|
|
@ -0,0 +1,29 @@
|
||||||
|
Lugupeetud domeeni <%= @domain.name %> tehniline kontakt,
|
||||||
|
|
||||||
|
Eesti Interneti Sihtasutusele (EIS) juhib tähelepanu, et domeeni <%= @domain.name %> DNSKEY kirjed on puudulikud ning domeeniga seotud teenuse ei pruugi korrektselt toimida.
|
||||||
|
Andmete parandamiseks vaadake palun üle domeeni nimeserverite seaditused või pöörduge palun oma registripidaja <%= @domain.registrar.name %> või nimeserveri teenuse pakkuja poole.
|
||||||
|
|
||||||
|
Lisaküsimuste korral võtke palun ühendust oma registripidajaga:
|
||||||
|
<%= @domain.registrar.name%>
|
||||||
|
Email: <%= @domain.registrar.email %>
|
||||||
|
Telefon: <%= @domain.registrar.phone %>
|
||||||
|
Veebileht: <%= @domain.registrar.website %>
|
||||||
|
|
||||||
|
Lugupidamisega
|
||||||
|
Eesti Interneti Sihtasutus
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
Dear technical contact of <%= @domain.name %> domain,
|
||||||
|
|
||||||
|
Estonian Internet Foundation points out that the DNSKEY record(s) for the domain <%= @domain.name %> are invalid and the service related to the domain may not work correctly.
|
||||||
|
Please check the DNSKEY records of the domain or contact your registrar <%= @domain.registrar.name%> or your name server service provider to correct this information.
|
||||||
|
|
||||||
|
Should you have additional questions, please contact your registrar:
|
||||||
|
<%= @domain.registrar.name%>
|
||||||
|
Email: <%= @domain.registrar.email %>
|
||||||
|
Phone: <%= @domain.registrar.phone %>
|
||||||
|
Website: <%= @domain.registrar.website %>
|
||||||
|
|
||||||
|
Best Regards,
|
||||||
|
Estonian Internet Foundation
|
|
@ -0,0 +1,43 @@
|
||||||
|
<h2>Lugupeetud domeeni <%= @domain.name %> tehniline kontakt</h2>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
Eesti Interneti Sihtasutusele (EIS) juhib tähelepanu, et domeeni <%= @domain.name %> nimeserverite seaded on puudulikud ning domeeniga seotud teenuse ei pruugi korrektselt toimida.</p>
|
||||||
|
<p>
|
||||||
|
Andmete parandamiseks vaadake palun üle domeeni nimeserverite seaditused või pöörduge palun oma registripidaja <%= @domain.registrar.name%> või nimeserveri teenuse pakkuja poole.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
Lisaküsimuste korral võtke palun ühendust oma registripidajaga:
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<b><%= @domain.registrar.name %></b><br />
|
||||||
|
<b>Email:</b> <%= @domain.registrar.email %><br />
|
||||||
|
<b>Telefon:</b> <%= @domain.registrar.phone %><br />
|
||||||
|
<b>Veebileht:</b> <%= @domain.registrar.website %><br />
|
||||||
|
|
||||||
|
Lugupidamisega<br />
|
||||||
|
<b>Eesti Interneti Sihtasutus</b><br />
|
||||||
|
<br />
|
||||||
|
---
|
||||||
|
<br />
|
||||||
|
|
||||||
|
<h2>Dear technical contact of <%= @domain.name %> domain,</h2>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
Estonian Internet Foundation points out that the settings for the name servers of the domain <%= @domain.name %> are incomplete and the service related to the domain may not work correctly.
|
||||||
|
</p>
|
||||||
|
<p>
|
||||||
|
Please check the name server settings of the domain or contact your registrar <%= @domain.registrar.name%> or your name server service provider to correct this information.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
Should you have additional questions, please contact your registrar:
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<b><%= @domain.registrar.name%></b><br />
|
||||||
|
<b>Email:</b> <%= @domain.registrar.email %><br />
|
||||||
|
<b>Phone:</b> <%= @domain.registrar.phone %><br />
|
||||||
|
<b>Website:</b> <%= @domain.registrar.website %><br />
|
||||||
|
|
||||||
|
Best Regards,<br />
|
||||||
|
<b>Estonian Internet Foundation</b><br />
|
|
@ -0,0 +1,29 @@
|
||||||
|
Lugupeetud domeeni <%= @domain.name %> tehniline kontakt
|
||||||
|
|
||||||
|
Eesti Interneti Sihtasutusele (EIS) juhib tähelepanu, et domeeni <%= @domain.name %> nimeserverite seaded on puudulikud ning domeeniga seotud teenuse ei pruugi korrektselt toimida.
|
||||||
|
Andmete parandamiseks vaadake palun üle domeeni nimeserverite seaditused või pöörduge palun oma registripidaja <%= @domain.registrar.name%> või nimeserveri teenuse pakkuja poole.
|
||||||
|
|
||||||
|
Lisaküsimuste korral võtke palun ühendust oma registripidajaga:
|
||||||
|
<%= @domain.registrar.name%>
|
||||||
|
Email: <%= @domain.registrar.email %>
|
||||||
|
Telefon: <%= @domain.registrar.phone %>
|
||||||
|
Veebileht: <%= @domain.registrar.website %>
|
||||||
|
|
||||||
|
Lugupidamisega
|
||||||
|
Eesti Interneti Sihtasutus
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
Dear technical contact of <%= @domain.name %> domain,
|
||||||
|
|
||||||
|
Estonian Internet Foundation points out that the settings for the name servers of the domain <%= @domain.name %> are incomplete and the service related to the domain may not work correctly.
|
||||||
|
Please check the name server settings of the domain or contact your registrar <%= @domain.registrar.name%> or your name server service provider to correct this information.
|
||||||
|
|
||||||
|
Should you have additional questions, please contact your registrar:
|
||||||
|
<%= @domain.registrar.name%>
|
||||||
|
Email: <%= @domain.registrar.email %>
|
||||||
|
Phone: <%= @domain.registrar.phone %>
|
||||||
|
Website: <%= @domain.registrar.website %>
|
||||||
|
|
||||||
|
Best Regards,
|
||||||
|
Estonian Internet Foundation
|
Loading…
Add table
Add a link
Reference in a new issue