Skip to content

Deploy a React or Vite app

This guide replaces the old “How to deploy React JS app on DockHive” page.

Push your code to GitHub, start a new app, pick the repository and click Deploy with Drone. Or run hivepod deploy in the project folder.

Pick React (Vite or Create React App), Vue, Svelte, Angular or Vite. DockHive runs your build script and serves the built files.

package.json
{
"scripts": {
"dev": "vite",
"build": "vite build"
}
}
  • Client-side routing: single-page apps get their index.html for unknown paths, so React Router and similar work on refresh.
  • Don’t deploy the dev server. vite and vite preview aren’t meant for production and refuse unknown hostnames.
  • Build-time variables: VITE_* values are baked into the bundle and visible to anyone. Never put secrets in them. See Environment variables.
  • Backends: deploy your API as a separate app and call it by its address.