How Publishing Works
When you publish your app, OptiDev:- Builds your project (compiles all the code)
- Uploads it to our global network
- Gives you a live URL anyone can visit
yourproject.dev.optidev.com. You can also use your own domain.
Publishing Your App
From the Dashboard
- Open your project in OptiDev
- Click the Publish button in the top-right corner
- Wait for the build to complete (usually 1-2 minutes)
- Your live URL appears when ready
Using Agent Mode
Just ask the agent:“Publish my app”The agent handles the build and deploy process for you.
What Happens During Publishing
Build Phase
OptiDev compiles your code into optimized files:- Bundles JavaScript for faster loading
- Optimizes images
- Minifies code (makes files smaller)
Deploy Phase
After a successful build:- Files upload to CloudFlare’s global network
- Your app becomes available worldwide
- SSL certificate ensures secure connections (https)
Checking Deploy Status
View Recent Deploys
- Open your project
- Click Settings → Deploys
- See a list of all deployments with status and date
Deploy Statuses
| Status | Meaning |
|---|---|
| Building | Code is being compiled |
| Deploying | Files are being uploaded |
| Live | Your app is published and accessible |
| Failed | Something went wrong (see error message) |
Fixing Build Errors
If publishing fails, you’ll see an error message. Common issues: “Build failed”- Ask the agent: “The build failed, can you fix it?”
- The agent reviews the error and makes corrections
- Usually means a package wasn’t installed correctly
- Ask the agent: “Install missing dependencies and try again”
Rollback to Previous Version
Made a mistake? You can go back to an earlier version:- Go to Settings → Deploys
- Find the version you want to restore
- Click Rollback
- Confirm the rollback
Preview Before Publishing
Want to test before going live? Your project has a live preview while you’re editing. The preview URL is only accessible to you. Once you’re happy with the preview, publish to make it public.For Developers
Build System
Builds run as Kubernetes Jobs with:- Auto-detection of package manager (npm, yarn, pnpm)
- Node.js 22 environment
- 2 CPU, 4GB RAM allocation
- 15-minute timeout
- Presigned URLs for artifact upload
Build Process
Deploy System
- Static files uploaded to CloudFlare R2
- Environment variables injected via
window.__ENV__ - CloudFlare Workers serve content from R2
- Automatic SSL via CloudFlare
API Reference
Build Logs
Build logs are always uploaded, even on failure. Access via:- Dashboard: Settings → Deploys → Click deploy → View Logs
- API:
GET /api/builds/:buildId/logs