Update admin email to matt@puffinoffset.com
All checks were successful
Build and Push Docker Images / docker (push) Successful in 58s

- Update default admin email from admin@ to matt@puffinoffset.com
- Add ADMIN_EMAIL environment variable to docker-compose.yml
- Add complete Email Configuration section to .env.example
- Admin email receives contact form submissions and order notifications

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Matt 2025-10-31 21:01:57 +01:00
parent a23cdfe396
commit 0b66378423
3 changed files with 13 additions and 2 deletions

View File

@ -31,6 +31,16 @@ WREN_DRY_RUN=true
# === Database Configuration === # === Database Configuration ===
DATABASE_PATH=/app/data/orders.db DATABASE_PATH=/app/data/orders.db
# === Email Configuration ===
SMTP_HOST=mail.puffinoffset.com
SMTP_PORT=587
SMTP_SECURE=false
SMTP_USER=noreply@puffinoffset.com
SMTP_PASSWORD=your_smtp_password_here
SMTP_FROM_NAME=Puffin Offset
SMTP_FROM_EMAIL=noreply@puffinoffset.com
ADMIN_EMAIL=matt@puffinoffset.com
# ======================================== # ========================================
# NOTES # NOTES
# ======================================== # ========================================

View File

@ -45,6 +45,7 @@ services:
- SMTP_PASSWORD=${SMTP_PASSWORD} - SMTP_PASSWORD=${SMTP_PASSWORD}
- SMTP_FROM_NAME=${SMTP_FROM_NAME} - SMTP_FROM_NAME=${SMTP_FROM_NAME}
- SMTP_FROM_EMAIL=${SMTP_FROM_EMAIL} - SMTP_FROM_EMAIL=${SMTP_FROM_EMAIL}
- ADMIN_EMAIL=${ADMIN_EMAIL:-matt@puffinoffset.com}
dns: dns:
- 8.8.8.8 - 8.8.8.8
- 8.8.4.4 - 8.8.4.4

View File

@ -126,7 +126,7 @@ export async function sendReceiptEmail(customerEmail, orderDetails) {
// Send contact form email // Send contact form email
export async function sendContactEmail(contactData) { export async function sendContactEmail(contactData) {
const subject = `Contact Form: ${contactData.name}`; const subject = `Contact Form: ${contactData.name}`;
const adminEmail = process.env.ADMIN_EMAIL || 'admin@puffinoffset.com'; const adminEmail = process.env.ADMIN_EMAIL || 'matt@puffinoffset.com';
return await sendTemplateEmail( return await sendTemplateEmail(
adminEmail, adminEmail,
@ -152,7 +152,7 @@ export async function sendContactEmail(contactData) {
// Send admin notification for new order // Send admin notification for new order
export async function sendAdminNotification(orderDetails, customerEmail) { export async function sendAdminNotification(orderDetails, customerEmail) {
const subject = `New Order: ${orderDetails.tons} tons CO₂ - $${(orderDetails.totalAmount / 100).toFixed(2)}`; const subject = `New Order: ${orderDetails.tons} tons CO₂ - $${(orderDetails.totalAmount / 100).toFixed(2)}`;
const adminEmail = process.env.ADMIN_EMAIL || 'admin@puffinoffset.com'; const adminEmail = process.env.ADMIN_EMAIL || 'matt@puffinoffset.com';
// Check if admin notifications are enabled // Check if admin notifications are enabled
if (process.env.ADMIN_NOTIFY_ON_ORDER === 'false') { if (process.env.ADMIN_NOTIFY_ON_ORDER === 'false') {