â ī¸ Prerequisite: Complete Server Setup First!
Before proceeding with installation, you must complete the server preparation steps including:
- â Server requirements verification (PHP 8.2+, MySQL 8.0+, etc.)
- â Domain configuration and DNS setup
- â Control panel configuration (Hestia, aaPanel, or cPanel)
- â File and folder permissions setup
- â Database creation and import
đ Quick Navigation
- 1. Basic Installation Steps
- 2. Alternative Deployment (Separate Folders)
- 3. Installation Wizard Walkthrough
- 4. Post-Installation Setup
- 5. Advanced Configuration (OAuth, AI, Redis, CDN)
- 6. Frontend Deployment (Advanced)
- 7. Troubleshooting Common Issues
- 8. Updates & Upgrades
- 9. Backup & Restore
- 10. Payment Webhooks Setup
1. Basic Installation Steps
Step-by-Step Installation
- Extract
ashie-resume-backend.zipon your computer - Upload all extracted files to your server's web root directory
- Common locations:
/var/www/html,/home/username/public_html, or/usr/share/nginx/html
- Access your control panel or phpMyAdmin
- Create a new MySQL database (e.g.,
ashie_resume_db) - Create a database user with a strong password
- Grant ALL PRIVILEGES to the user on the database
- Open phpMyAdmin and select your database
- Click "Import" tab
- Choose
database.sqlfile - Click "Go" to import
- Locate
.env.examplefile in the root directory - Rename it to
.env - Edit
.envfile and update these values:
APP_URL=https://yourdomain.com
DB_DATABASE=ashie_resume_db
DB_USERNAME=your_database_user
DB_PASSWORD=your_database_password
.env file or commit it to version control. It contains sensitive credentials!
cd /path/to/your/application
composer install --no-dev --optimize-autoloader
php artisan key:generate
php artisan storage:link
php artisan config:cache
php artisan route:cache
php artisan view:cache
2. Alternative Deployment: Separate Frontend & Backend Folders
Structure:
- Frontend files:
public_html/(root directory) - Backend folder:
public_html/backend/ - Access:
yourdomain.com(frontend) - API:
yourdomain.com/backend/api/v1
# Step 1: Navigate to frontend directory
cd ~/public_html
# Step 2: Install dependencies
npm install
# Step 3: Build for production
npm run build
- SSH access to your server
- Node.js 20.x+ and npm installed
- Frontend source files (separate from backend package)
- Text editor to modify .env files
Step-by-Step Deployment Process
- Extract
ashie-resume-backend.zipto a folder on your computer - Using FTP/SFTP, upload the entire backend folder to your server's root directory
- Final path:
public_html/backend/(you can rename "backend" to anything, but keep files inside)
public_html/
âââ backend/ â Backend folder (you can rename this)
âââ app/
âââ bootstrap/
âââ config/
âââ database/
âââ public/
âââ routes/
âââ storage/
âââ vendor/
âââ .env.example
âââ artisan
âââ composer.json
- Extract frontend source files to a folder on your computer
- Upload all frontend files directly to
public_html/(NOT in a subfolder) - Files should be at root level alongside the backend folder
public_html/
âââ backend/ â Backend folder
âââ src/ â Frontend source
âââ public/ â Frontend public assets
âââ node_modules/ â Will be created after npm install
âââ .env â Frontend environment config
âââ package.json
âââ vite.config.js
âââ index.html
- Navigate to
public_html/backend/ - Copy
.env.exampleto.env - Edit
.envand update these values:
# Application
APP_NAME="Ashie Resume"
APP_ENV=production
APP_DEBUG=false
APP_URL=https://yourdomain.com/backend
# Database
DB_CONNECTION=mysql
DB_HOST=127.0.0.1
DB_PORT=3306
DB_DATABASE=your_database_name
DB_USERNAME=your_database_user
DB_PASSWORD=your_database_password
# CORS (Allow frontend domain)
SANCTUM_STATEFUL_DOMAINS=yourdomain.com
SESSION_DOMAIN=.yourdomain.com
# Other settings...
# (Configure mail, payment gateways, etc.)
- Navigate to
public_html/(frontend root) - Create or edit the
.envfile - Add these configurations:
# Frontend Environment Configuration
VITE_FRONTEND_URL=https://yourdomain.com
VITE_API_URL=https://yourdomain.com/backend/api/v1
VITE_BASE_URL=https://yourdomain.com/backend
VITE_STORAGE_URL=https://yourdomain.com/backend/storage
VITE_APP_NAME=AshieJobPortal
# Stripe (Optional - if using payments)
VITE_STRIPE_PUBLISHABLE_KEY=pk_live_your_stripe_key_here
yourdomain.com with your actual domain name in ALL the URLs above!
# SSH into your server
ssh username@your-server-ip
# Navigate to backend folder
cd /home/username/public_html/backend
# Set permissions
chmod -R 755 .
chmod -R 775 storage
chmod -R 775 bootstrap/cache
chown -R www-data:www-data storage
chown -R www-data:www-data bootstrap/cache
# Still in backend folder
cd /home/username/public_html/backend
# Install Composer dependencies
composer install --no-dev --optimize-autoloader
# Generate application key
php artisan key:generate
# Create storage link
php artisan storage:link
# Cache configurations (optional, for performance)
php artisan config:cache
php artisan route:cache
php artisan view:cache
# Navigate to frontend root (where package.json is)
cd /home/username/public_html
# Install Node.js dependencies
npm install
# Build frontend for production
npm run build
# This will create optimized production files
vite v6.4.1 building for production...
â 1234 modules transformed.
dist/assets/index-a1b2c3d4.js 152.34 kB â gzip: 26.78 kB
dist/assets/index-e5f6g7h8.css 45.67 kB â gzip: 8.12 kB
â built in 12.34s
- For Nginx: Create two location blocks
# Nginx configuration example
server {
listen 80;
server_name yourdomain.com;
root /home/username/public_html;
index index.html;
# Frontend (React SPA)
location / {
try_files $uri $uri/ /index.html;
}
# Backend API
location /backend {
alias /home/username/public_html/backend/public;
try_files $uri $uri/ @backend;
location ~ \.php$ {
include fastcgi_params;
fastcgi_pass unix:/var/run/php/php8.2-fpm.sock;
fastcgi_param SCRIPT_FILENAME $request_filename;
}
}
location @backend {
rewrite /backend/(.*)$ /backend/index.php?/$1 last;
}
}
- For Apache: Ensure .htaccess files are present
# Create .htaccess in public_html/backend/public/
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /backend/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php/$1 [L]
</IfModule>
# Create .htaccess in public_html/ (frontend root)
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /index.html [L]
</IfModule>
- Frontend: Visit
https://yourdomain.com- Should show homepage - Backend API: Visit
https://yourdomain.com/backend/api/v1/health- Should return JSON - Admin Panel: Visit
https://yourdomain.com/backend/admin - Browser Console: Press F12 â Check for errors
- Network Tab: Verify API calls go to
/backend/api/v1/*
- Visit
https://yourdomain.com - You'll be automatically redirected to the installation wizard
- Follow the on-screen instructions to:
- Verify server requirements
- Configure database (should already be in backend .env)
- Run migrations
- Activate license
Troubleshooting This Deployment Method
- Solution 1: Verify frontend
.envhas correctVITE_API_URL - Solution 2: Check web server configuration (Nginx/Apache) for backend routing
- Solution 3: Test backend directly:
https://yourdomain.com/backend/api/v1/health - Solution 4: Clear browser cache (Ctrl+Shift+R)
- Solution: Update backend
.envCORS settings:SANCTUM_STATEFUL_DOMAINS=yourdomain.com SESSION_DOMAIN=.yourdomain.com CORS_ALLOWED_ORIGINS=https://yourdomain.com - Then clear Laravel cache:
cd /home/username/public_html/backend php artisan config:clear php artisan cache:clear
- Solution 1: Check if
npm run buildcompleted successfully - Solution 2: Verify
dist/folder was created withindex.htmlandassets/ - Solution 3: Check browser console (F12) for JavaScript errors
- Solution 4: Verify frontend
.envfile exists and has correct values - Solution 5: Rebuild frontend:
cd /home/username/public_html rm -rf node_modules dist npm install npm run build
- Solution: Check file permissions:
cd /home/username/public_html chmod -R 755 dist chmod -R 755 public
Updating After Changes
# SSH into server
cd /home/username/public_html
# Rebuild frontend
npm run build
# Clear browser cache (on your computer)
# Ctrl+Shift+R or Ctrl+F5
# SSH into server
cd /home/username/public_html/backend
# Clear Laravel caches
php artisan config:clear
php artisan cache:clear
php artisan route:clear
php artisan view:clear
# Re-cache for production (optional)
php artisan config:cache
php artisan route:cache
Your application is now running with:
- Frontend:
https://yourdomain.com - Backend API:
https://yourdomain.com/backend/api/v1 - Admin Panel:
https://yourdomain.com/backend/admin
3. Installation Wizard Walkthrough
Accessing the Wizard
https://yourdomain.com/wizard
- Make sure you've uploaded all files
- Check that .env file is configured
- Verify database is imported
- Clear browser cache
Wizard Step 1: Welcome Screen
- Welcome message
- Brief overview of installation process
- System requirements check
- Review the welcome information
- Click Next or Get Started button
Wizard Step 2: Server Requirements Check
- PHP version (should be 8.2+)
- List of required PHP extensions
- â Green checkmarks for met requirements
- â Red X for missing requirements
- Ensure ALL requirements show â green checkmarks
- If any show â red, contact your hosting provider
- Click Next when all requirements are met
- Shared Hosting: Enable via cPanel â Select PHP Version
- VPS/Dedicated: Install via SSH (see Server Setup - Requirements)
- Contact Support: Ask to enable missing PHP extensions
Wizard Step 3: File Permissions Check
- List of directories that need write permissions
- â Green = Writable (good)
- â Red = Not writable (fix needed)
- All folders must show â green status
- If any show â, set permissions to 775 (see Server Setup - Permissions)
- Click Check Again after fixing permissions
- Click Next when all show green
Wizard Step 4: Database Configuration
A form with these fields:
| Field | What to Enter | Example |
|---|---|---|
| Database Host | Usually localhost or 127.0.0.1 |
localhost |
| Database Port | Usually 3306 (leave default) |
3306 |
| Database Name | The database you created earlier | ashie_resume_db |
| Database Username | The database user you created | ashie_user |
| Database Password | The password for database user | YourStrongPassword123! |
- Fill in all database fields carefully
- Double-check for typos (common mistake!)
- Click Test Connection button
- Wait for "â Connection Successful" message
- Click Next to continue
- Database host is correct (usually localhost)
- Database name matches exactly (case-sensitive)
- Username and password are correct
- Database user has ALL PRIVILEGES
- MySQL service is running
Wizard Step 5: Demo Users Information
The sample database includes three fully functional demo accounts for testing all features.
Demo User Credentials
| Account Type | Name | Password | Access Level | |
|---|---|---|---|---|
| đ Super Admin | Super Admin | superadmin@test.com |
password123 |
Full system access, all permissions |
| đ Employer | Jane Employer | employer@test.com |
password123 |
Post jobs, manage applications |
| đ¤ Job Seeker | David Seeker | seeker@test.com |
password123 |
Create resumes, apply for jobs |
- IMMEDIATELY change all passwords after installation!
- Go to Admin Panel â Users â Edit each user
- Set strong, unique passwords for production use
- Consider deleting demo accounts and creating new ones
- NEVER use
password123in production!
- Review the demo user information
- Write down or save these credentials
- Click Next or Continue to proceed
- After installation, login as superadmin@test.com
- Immediately change all default passwords!
Wizard Step 6: License Activation
- Purchase code input field
- Domain verification
- License activation form
| Field | What to Enter |
|---|---|
| Full Name | Your full name as the buyer |
| Purchase Code | Your license key from purchase |
| Envato Username | Your Envato/CodeCanyon username |
| Domain | Your website domain (auto-detected) |
| Buyer Email | Email used for purchase |
- Enter your purchase code (from marketplace)
- Verify domain is correct
- Enter buyer email
- Click Activate License
- Wait for "â License Activated Successfully"
- Click Next
- Invalid Code: Double-check purchase code
- Already Used: License already activated on another domain
- Suspended: Contact support for license issues
- Network Error: Check internet connection
Wizard Step 7: Installation Progress
- Progress bar
- List of installation tasks
- â Checkmarks as tasks complete
- â Creating database tables
- â Importing default data
- â Setting up admin account
- â Configuring application settings
- â Generating security keys
- â Creating storage directories
- â Finalizing installation
Wizard Step 8: Installation Complete!
- Success message
- Demo login credentials reminder
- Links to admin panel and frontend
- Important next steps
| Super Admin: | superadmin@test.com / password123 |
| Employer: | employer@test.com / password123 |
| Job Seeker: | seeker@test.com / password123 |
- Click Go to Admin Panel
- Login with:
superadmin@test.com/password123 - IMMEDIATELY change the default password!
- Change passwords for all demo accounts
- Complete post-installation setup (next section)
4. Post-Installation Setup
Essential Post-Installation Tasks
The application uses background jobs for emails, AI features, payment processing, and notifications. Without queue workers, these features will NOT work!
đ Setting Up Queue Workers
Queue workers process background jobs like email sending, AI operations, payment webhooks, and scheduled tasks. You MUST configure these for full functionality.
Option 1: Supervisor (Recommended for Production)
# Install Supervisor
sudo apt install supervisor
# Create supervisor configuration
sudo nano /etc/supervisor/conf.d/ashie-resume-worker.conf
Add this configuration:
[program:ashie-resume-worker]
process_name=%(program_name)s_%(process_num)02d
command=php /path/to/your/application/artisan queue:work --sleep=3 --tries=3 --max-time=3600
autostart=true
autorestart=true
stopasgroup=true
killasgroup=true
user=www-data
numprocs=2
redirect_stderr=true
stdout_logfile=/path/to/your/application/storage/logs/worker.log
stopwaitsecs=3600
Activate the supervisor config:
# Reload supervisor
sudo supervisorctl reread
sudo supervisorctl update
sudo supervisorctl start ashie-resume-worker:*
# Check status
sudo supervisorctl status
Option 2: Cron-based Queue (Alternative for Shared Hosting)
If you can't use Supervisor, add this to your crontab:
# Run queue worker every minute
* * * * * cd /path/to/your/application && php artisan queue:work --stop-when-empty --max-time=55 >> /dev/null 2>&1
Option 3: Database Queue (Default)
The application defaults to database queue. Make sure this is set in your .env:
QUEUE_CONNECTION=database
- Email Sending: Password resets, notifications, application confirmations
- AI Operations: Resume optimization, cover letter generation, job matching
- Payment Processing: Subscription webhooks, payment confirmations
- File Processing: Resume PDF generation, image optimization
- Scheduled Tasks: System maintenance, cleanup jobs
Visit:
https://yourdomain.com/adminUse demo credentials:
superadmin@test.com / password123
- Go to Users menu in admin panel
- Edit Super Admin (superadmin@test.com)
- Set a strong new password (12+ characters, mixed case, numbers, symbols)
- Save changes
- Repeat for employer@test.com and seeker@test.com
- Consider creating new admin accounts with your own email
- Optional: Delete demo accounts after creating new ones
- Go to Settings â General
- Update site name, logo, favicon
- Set timezone and date format
- Configure contact information
- Go to Settings â Email
- Configure SMTP settings or use default
- Test email sending functionality
- Go to Settings â Payments
- Enable desired payment methods
- Enter API keys for Stripe, PayPal, etc.
- Set currency and payment mode (test/live)
Required for background tasks like:
- Job Match Alerts: Daily emails to job seekers with matching jobs (9 AM)
- Job Expiry Alerts: Notifications about expiring job postings (8 AM)
- Subscription Checks: Verify and expire subscriptions (every 5 minutes)
- Security Cleanup: Remove expired IP blocks (hourly)
- System Maintenance: Database optimization, cache cleanup (daily)
* * * * * cd /path/to/your/application && php artisan schedule:run >> /dev/null 2>&1
- Install SSL certificate (Let's Encrypt is free)
- Update .env file:
APP_URL=https://yourdomain.com - Force HTTPS in web server configuration
- Clear cache:
php artisan config:clear
- â User registration and login
- â Job posting creation
- â Resume upload and generation
- â Email notifications
- â Payment processing (use test mode)
- â File uploads and downloads
- Backup database regularly
- Backup uploaded files in
storage/ - Keep .env file backup securely
- Setup automated backups if possible
- Set
APP_DEBUG=falsein production - All demo passwords must be changed (already done in step 2)
- Consider deleting demo accounts: seeker@test.com, employer@test.com
- Create new accounts with real email addresses
- Enable firewall on server
- Keep application updated
- Monitor error logs regularly
5. Advanced Configuration (Optional)
đ Social Login Configuration (Google & Facebook)
Allow users to sign in with their Google or Facebook accounts for faster registration and better user experience.
- Increases registration conversion by 50%+
- Users don't need to remember another password
- Reduces fake account registrations
- Provides verified email addresses
đĩ Google OAuth Setup (Step-by-Step)
- Click the project dropdown â New Project
- Enter project name â Click Create
- Go to APIs & Services â OAuth consent screen
- Select External â Click Create
- Fill in App name, support email, developer email
- Add scopes:
email,profile,openid
- Go to Credentials â Create Credentials â OAuth client ID
- Application type: Web application
- Authorized redirect URIs:
https://yourdomain.com/api/v1/auth/google/callback
# Google OAuth Configuration
GOOGLE_CLIENT_ID=your_client_id_here
GOOGLE_CLIENT_SECRET=your_client_secret_here
GOOGLE_REDIRECT_URI="${APP_URL}/api/v1/auth/google/callback"
đˇ Facebook OAuth Setup (Step-by-Step)
- Click My Apps â Create App
- Select: Authenticate and request data from users
- App type: Consumer
- Add Facebook Login product
- Go to Facebook Login â Settings
- Valid OAuth Redirect URIs:
https://yourdomain.com/api/v1/auth/facebook/callback
# Facebook OAuth Configuration
FACEBOOK_CLIENT_ID=your_app_id_here
FACEBOOK_CLIENT_SECRET=your_app_secret_here
FACEBOOK_REDIRECT_URI="${APP_URL}/api/v1/auth/facebook/callback"
đ¤ OpenAI / AI Features Configuration
OpenAI powers resume optimization, cover letter generation, and job matching features.
.env file:
# OpenAI Configuration
OPENAI_API_KEY=sk-proj-your-api-key-here
⥠Redis Cache Configuration (Recommended)
Redis significantly improves performance by caching database queries and sessions.
# Install Redis (Ubuntu/Debian)
sudo apt update
sudo apt install redis-server php8.2-redis
sudo systemctl start redis-server
sudo systemctl enable redis-server
# Verify
redis-cli ping # Should return PONG
Update your .env file:
# Cache with Redis
CACHE_STORE=redis
SESSION_DRIVER=redis
QUEUE_CONNECTION=redis
# Redis connection
REDIS_HOST=127.0.0.1
REDIS_PASSWORD=null
REDIS_PORT=6379
đ CDN Configuration (Optional)
Use a CDN to serve static assets faster globally.
# Add to .env file
CDN_ENABLED=true
CDN_PROVIDER=cloudflare
CLOUDFLARE_ZONE_ID=your_zone_id
CLOUDFLARE_API_TOKEN=your_api_token
CLOUDFLARE_CDN_DOMAIN=cdn.yourdomain.com
đ Pusher Configuration (Real-Time Chat)
Pusher enables real-time messaging between employers and job seekers.
.env:
BROADCAST_CONNECTION=pusher
PUSHER_APP_ID=your_app_id
PUSHER_APP_KEY=your_app_key
PUSHER_APP_SECRET=your_app_secret
PUSHER_APP_CLUSTER=eu
6. Frontend Deployment (Advanced)
backend/public folder.
This section is only for developers who want to rebuild the frontend from source.
Quick Rebuild Commands
# Navigate to frontend directory
cd frontend
# Install dependencies (first time only)
npm install
# Build for production
npm run build
# Navigate back and clear caches
cd ../backend
php artisan config:clear
php artisan cache:clear
7. Troubleshooting Common Issues
Issue #1: White Screen / Blank Page
- Enable debug:
APP_DEBUG=truein .env - Check PHP error logs
- Verify PHP extensions are enabled
- Check storage/ folder permissions (775)
- Clear cache:
php artisan config:clear && php artisan cache:clear
Issue #2: 500 Internal Server Error
- Check web server error logs
- Verify .env file exists
- Check APP_KEY is set
- Ensure storage/ has 775 permissions
Issue #3: Database Connection Error
- Verify database credentials in .env
- Check MySQL service is running
- Try
127.0.0.1instead oflocalhost - Verify database user has ALL PRIVILEGES
Issue #4: Email Not Sending
- Verify SMTP settings in .env
- Check spam/junk folders
- Run queue worker:
php artisan queue:work
Issue #5: License Activation Failed
- Verify purchase code is correct
- Check server internet connection
- Contact support if code says "already used"
8. Updates & Upgrades
Update Process
- Backup database and files
- Put site in maintenance:
php artisan down - Download new version
- Upload new files (except .env and storage/app/)
- Run update commands:
composer install --no-dev --optimize-autoloader php artisan migrate --force php artisan config:cache php artisan route:cache php artisan view:cache - Bring site online:
php artisan up
9. Backup & Restore
Database Backup
# MySQL backup
mysqldump -u username -p database_name > backup.sql
# Compressed backup
mysqldump -u username -p database_name | gzip > backup.sql.gz
File Backup
# Backup storage folder
tar -czvf storage_backup.tar.gz storage/app/
# Backup .env file
cp .env .env.backup
Restore
# Restore database
mysql -u username -p database_name < backup.sql
# Restore files
tar -xzvf storage_backup.tar.gz
10. Payment Webhooks Setup
Webhook URLs
| Gateway | Webhook URL |
|---|---|
| Stripe | https://yourdomain.com/api/v1/payment/webhook/stripe |
| PayPal | https://yourdomain.com/api/v1/payment/webhook/paypal |
| Flutterwave | https://yourdomain.com/api/v1/payment/webhook/flutterwave |
| Paystack | https://yourdomain.com/api/v1/payment/webhook/paystack |
| Razorpay | https://yourdomain.com/api/v1/payment/webhook/razorpay |
Stripe Webhook Events
Select these events when configuring:
checkout.session.completedcustomer.subscription.updatedcustomer.subscription.deletedinvoice.paidinvoice.payment_failed
# Add Stripe webhook secret to .env
STRIPE_WEBHOOK_SECRET=whsec_your_webhook_secret_here