Skip to content

Configuring Build and Start Commands

The build command and start command are essential for preparing and running your application on Seenode.

  • The build command installs dependencies and compiles or prepares your application for execution.
  • The start command starts your application, making it available for requests.

Seenode attempts to automatically detect these commands, but you can customize them based on your project’s needs.

Here are some common examples for different frameworks.

Build Command

Terminal
npm install

Start Command

Terminal
node server.js

Sometimes, you need to run additional commands as part of your build or start process. You can chain commands using &&.

It’s a common practice to run database migrations before starting the application.

  1. Chain the commands

    You can add the migration command to your start command, separated by &&.

    Django Example

    Terminal
    python manage.py migrate && gunicorn my-project.wsgi --bind 0.0.0.0:8000

    FastAPI with Alembic Example

    Terminal
    alembic upgrade head && uvicorn main:app --host 0.0.0.0 --port 8000
  2. Use a startup script

    For more complex startup sequences, you can create a script.

    startup.sh

    startup.sh
    #!/bin/sh
    # Run migrations
    python manage.py migrate
    # Start the application
    gunicorn my-project.wsgi --bind 0.0.0.0:8000

    Make the script executable: chmod +x startup.sh

    Then, set your start command to:

    Terminal
    ./startup.sh