Getting Started
Server Setup
This guide covers deploying Framecast AI on your own server (VPS, dedicated server, or cloud VM). You will need root or sudo access to the server and a domain name pointed to it.
Connecting to Your Server
SSH into your server from your local terminal:
ssh root@your-server-ipInstalling Nginx
Nginx acts as a reverse proxy, forwarding incoming HTTP requests to your Next.js application running on port 3000.
Configure Firewall
Allow HTTP and HTTPS traffic through the firewall:
sudo ufw allow "Nginx HTTP"
sudo ufw allow "Nginx HTTPS"
sudo ufw allow OpenSSH
sudo ufw enableVerify the firewall status:
sudo ufw statusConfigure Reverse Proxy
Create a new Nginx configuration for your app:
sudo nano /etc/nginx/sites-enabled/nextjs.confPaste the following, replacing your-domain.com with your actual domain:
server {
listen 80;
server_name your-domain.com www.your-domain.com;
location / {
proxy_pass http://localhost:3000;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
}
}Save the file (Ctrl+O, then Ctrl+X), remove the default config, and restart Nginx:
sudo rm /etc/nginx/sites-enabled/defaultsudo systemctl restart nginxInstalling Node.js
Framecast AI requires Node.js v22. Install it using the NodeSource repository:
curl -fsSL https://deb.nodesource.com/setup_22.x | sudo -E bash -sudo apt install nodejs -yVerify the installation:
node --versionInstalling pnpm
Framecast AI uses pnpm as its package manager:
npm install -g pnpmInstalling Docker (Optional)
Docker is only required if you plan to self host Supabase on the same server. If you are using Supabase Cloud, you can skip this step.
curl -fsSL https://get.docker.com | sudo shsudo systemctl start docker && sudo systemctl enable dockerInstall Docker Compose:
sudo apt install docker-compose-plugin -yVerify both are installed:
docker --version && docker compose versionSetting Up SSL (Recommended)
Use Certbot to get a free SSL certificate from Let's Encrypt:
sudo apt install certbot python3-certbot-nginx -ysudo certbot --nginx -d your-domain.com -d www.your-domain.comCertbot will automatically configure Nginx to use HTTPS and set up auto renewal.
This completes the initial server setup. Next, configure your environment variables.