feat: require valid admin email for platform start
What issue type does this pull request address? (keep at least one, remove the others) /kind enhancement
What does this pull request do? Which issues does it resolve? (use resolves #<issue_number> if possible)
resolves #ENG-3850
What else do we need to know?
💡 The go:geneate portion can be removed if its seen as "overkill", I threw it in to make updating the list easier in the future.
Requirements from the issue:
If in interactive shell, then prompt for email address. With the email address:
Check if Valid Email - use a parser
Don't allow any disposable emails: Use this list to verify if it's a disposable one. This is in the existing email-verifier library. https://raw.githubusercontent.com/disposable/disposable-email-domains/master/domains.json
Check if mx_record is found
Connect to see if it's valid with a 10 second timeout. If it doesn't come back in 10 seconds, it's considered invalid.
If the validation step doesn't succeed, then keep asking the question.
By providing your email, you accept our Terms of Service and Privacy Statement:
Terms of Service: https://www.loft.sh/legal/terms
Privacy Statement: https://www.loft.sh/legal/privacy
Deploy Preview for vcluster-docs canceled.
Built without sensitive environment variables
| Name | Link |
|---|---|
| Latest commit | 38a47269a096199730dbac43a8a4d619caf5b782 |
| Latest deploy log | https://app.netlify.com/sites/vcluster-docs/deploys/670ecfd032460a00080b8991 |
@FabianKramm It looks like most of this code changes are from packaging the disposable domains. That file alone is 169,412 lines of code.
@zerbitx - Let's do this. Let's replace the list with this much smaller one: https://github.com/disposable-email-domains/disposable-email-domains/blob/main/disposable_email_blocklist.conf
That will significantly decrease the size of the PR.
@deniseschannon @FabianKramm I changed the list to be a zip file to make it smaller as an embed, using the condensed list suggested.