Frameworks and runtimes
What Rimbra detects, the command it runs for each language, and what your app needs to start.
The one rule for servers
If your app is a server, listen on the port in the PORT environment variable. Rimbra picks the port, sets PORT, and routes your domain to it.
js / python
// Node.js
const port = process.env.PORT || 3000
app.listen(port)
# Python
port = int(os.environ.get("PORT", 8000))What Rimbra detects
| Your files | Detected as | How it runs |
|---|---|---|
| package.json with next | Next.js | Builds, then runs the Next.js server |
| Vite, Astro, SvelteKit, Nuxt config | Frontend framework | Builds and serves the output |
| index.html | Static site | Served as files |
| package.json with a start script or server.js | Node server | npm start, or node on your entry file |
| requirements.txt or pyproject.toml | Python | Uvicorn for FastAPI, Gunicorn for Flask, runserver for Django |
| composer.json or index.php | PHP | PHP serving public/ or the project root |
| go.mod | Go | go build, then runs the binary |
| Cargo.toml | Rust | cargo build --release, then runs the binary |
| Gemfile with config.ru | Ruby | bundle exec rackup |
| pom.xml or build.gradle | Java | Maven package or Gradle bootJar, then java -jar |
| Dockerfile | Container | Builds the image and runs it with PORT set |
Python
- List dependencies in requirements.txt or pyproject.toml.
- Put your app in main.py, app.py, server.py or run.py, or use Django’s manage.py.
- For FastAPI, expose app = FastAPI(). Rimbra runs uvicorn main:app.
- For Flask, expose app = Flask(__name__) and include gunicorn or flask in your dependencies.
Node.js
- With a start script, Rimbra runs npm start (or the package manager your lockfile uses).
- Without one, it runs the file in "main", then server.js, index.js or app.js.
- Commit your lockfile so installs are fast and repeatable.
Override the commands
Open project Settings to set your own Root directory, Install command, Build command, Start command and Port. They are used from the next deployment.
| Setting | Default |
|---|---|
| Root directory | / |
| Install command | npm ci |
| Build command | npm run build |
| Start command | npm run start |
