Remove unused dbconfig.php include and add DNS resolution tests
All checks were successful
Deploy Production Email Reports (Unified) / deploy (push) Successful in 57s

This commit is contained in:
Frank John Begornia
2026-01-02 02:03:17 +08:00
parent 0ccda81dd7
commit 1c19c86205
2 changed files with 18 additions and 1 deletions

View File

@@ -27,8 +27,25 @@ php -v || { echo "PHP test failed"; exit 1; }
echo ""
echo "Environment variables loaded:"
echo " DB_HOST_CREW: ${DB_HOST_CREW:-not set}"
echo " DB_NAME_CREW: ${DB_NAME_CREW:-not set}"
echo " DB_USER_CREW: ${DB_USER_CREW:-not set}"
echo " DB_HOST_MERCHBAY: ${DB_HOST_MERCHBAY:-not set}"
echo " DB_NAME_MERCHBAY: ${DB_NAME_MERCHBAY:-not set}"
echo " DB_USER_MERCHBAY: ${DB_USER_MERCHBAY:-not set}"
echo " SMTP_HOST: ${SMTP_HOST:-not set}"
echo ""
# Test DNS resolution for database hosts
echo "Testing database host DNS resolution..."
if [ -n "${DB_HOST_CREW}" ]; then
echo -n " Crew DB (${DB_HOST_CREW}): "
getent hosts "${DB_HOST_CREW}" > /dev/null 2>&1 && echo "✓ Resolved" || echo "✗ Cannot resolve"
fi
if [ -n "${DB_HOST_MERCHBAY}" ]; then
echo -n " MerchBay DB (${DB_HOST_MERCHBAY}): "
getent hosts "${DB_HOST_MERCHBAY}" > /dev/null 2>&1 && echo "✓ Resolved" || echo "✗ Cannot resolve"
fi
echo ""
# Start crond in background
echo ""

View File

@@ -1,6 +1,6 @@
<?php
include 'dbconfig.php';
// dbconfig.php not needed - using environment variables directly
require("phpmailer/class.phpmailer.php");
date_default_timezone_set('America/Chicago');
$dateToday = date('Y-m-d');