Skip to content

al7566/De

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Privately - Affiliate & Security App

A full-stack web application for affiliate marketing management with AI-powered optimization and Android security dashboard capabilities.

Quick Start

Prerequisites

  • Node.js 20.x or higher
  • PostgreSQL database (get free at neon.tech)
  • npm package manager

Installation

  1. Clone the repository
git clone https://github.com/al7566/Affiliateandsecurityapp.git
cd Affiliateandsecurityapp
  1. Install dependencies
npm install
  1. Get a PostgreSQL Database (REQUIRED)

    • Sign up at neon.tech (free)
    • Create a new project
    • Copy the connection string
  2. Configure environment variables

cp .env.example .env

Edit .env with your configuration:

Required Variables (deployment will fail without these):

DATABASE_URL=postgresql://user:password@host:5432/database  # From Neon
ENCRYPTION_SECRET=$(openssl rand -hex 32)  # Generate with this command
NODE_ENV=production

Optional Variables (for full features):

AYRSHARE_API_KEY=your-api-key          # Social media posting
AYRSHARE_PROFILE_KEY=your-profile-key  # Social media profiles
CLICKBANK_SECRET_KEY=your-secret       # ClickBank affiliate
PORT=5000                               # Server port
  1. Validate your setup
npm run validate:env
  1. Initialize database
npm run db:push
  1. Build the application
npm run build
  1. Start the server
npm start

The application will be available at http://localhost:5000

Troubleshooting

If deployment fails, run:

npm run validate:deployment

This will check:

  • ✓ All required environment variables are set
  • ✓ Dependencies are installed
  • ✓ Build succeeds
  • ✓ Database connection works
  • ✓ No security vulnerabilities

See TROUBLESHOOTING.md for detailed solutions.

Development

Run in development mode with hot reload:

npm run dev

This starts both the client dev server (Vite) and the backend server.

Available Scripts

  • npm run dev - Start development server with hot reload
  • npm run build - Build for production
  • npm start - Start production server
  • npm run check - Run TypeScript type checking
  • npm run db:push - Initialize/update database schema
  • npm run validate:deployment - Check if ready to deploy
  • npm run validate:env - Check environment variables

Deployment

Pre-Deployment Checklist

Before deploying, run:

npm run validate:deployment

This ensures:

  • ✓ Required environment variables are set
  • ✓ Dependencies installed (569 packages)
  • ✓ No security vulnerabilities (0 in production)
  • ✓ Build succeeds
  • ✓ Database connection works

Quick Deploy Options

Heroku (easiest):

heroku create
heroku addons:create heroku-postgresql:mini
heroku config:set ENCRYPTION_SECRET=$(openssl rand -hex 32)
heroku config:set NODE_ENV=production
git push heroku main

Railway (recommended):

  1. Connect GitHub repo
  2. Add PostgreSQL database
  3. Set environment variables
  4. Auto-deploy enabled

Docker:

# Configure .env file first
docker-compose up -d

See DEPLOYMENT.md for detailed platform guides and TROUBLESHOOTING.md for common issues.

Features

  • 📊 Affiliate marketing dashboard with multi-network support
  • 🔐 Android security monitoring and privacy management
  • 💰 Real-time earnings tracking across ClickBank, ShareASale, CJ Affiliate
  • 🤖 AI-powered optimization and automation
  • 📱 Mobile-responsive cyberpunk UI
  • 🔒 Encrypted vault storage
  • 📈 Analytics and reporting
  • 🔄 Automatic data synchronization

Tech Stack

  • Frontend: React 19, TypeScript, Vite, Tailwind CSS, shadcn/ui
  • Backend: Node.js, Express, TypeScript
  • Database: PostgreSQL with Drizzle ORM
  • Authentication: Passport.js with session management
  • Real-time: WebSocket support

Support

For issues or questions, please open an issue on GitHub.

License

MIT

About

No description, website, or topics provided.

Resources

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages