Skip to main content

Develop and deploy your first Dagster pipeline

Welcome to Dagster+ Serverless! In this guide, we'll cover developing and testing your Dagster project locally, using branch deployments to safely test against production data, and finally, pushing your changes to production.

Dagster OSS and Dagster+ Hybrid users

To get started with Dagster+ Hybrid or Dagster OSS, see the Dagster+ Hybrid and OSS quickstart guide instead.

Prerequisites

To follow the steps in this guide, you will need to:

  • Sign up for a Dagster+ Serverless account and create a Dagster project
  • Clone your Dagster project to your local machine
  • Ensure you have Python 3.9+ installed
note

If you will be using pip, skip to step 2.

If you will be using uv as your package manager, follow the steps below to install the Python package manager uv:

brew install uv

Step 2: Install project dependencies

  1. Change to the directory of your cloned project:

    cd <project-directory>
  2. Activate the virtual environment:

    source .venv/bin/activate
  3. Install required dependencies in the virtual environment:

    uv sync

Step 3: Run your pipeline

  1. In the terminal, navigate to your project's root directory and run:

    dg dev
  2. Open your web browser and navigate to http://localhost:3000, where you should see the Dagster UI:

    Dagster UI overview

  3. In the top navigation, click the Assets tab, then click View lineage:

    Dagster UI asset lineage page

  4. To run the pipeline, click Materialize all:

    Dagster asset lineage page with materialize all button

  5. To view the run as it executes, click the Runs tab, then on the right side of the page, click View:

    Dagster run view

    To change how the run is displayed, you can use the view buttons in the top left corner of the page:

tip

You can also run the pipeline by using the dg launch --assets command and passing an asset selection:

dg launch --assets "*"

Step 4: Develop and test your pipeline

To develop your pipeline, you can:

To test your pipeline, you can:

Step 5: Deploy to staging with branch deployments

To see how your changes will look in production without altering production data, you can use branch deployments. To get started, make your changes in a Git branch and create a pull request, then select your branch from the deployment dropdown in the Dagster+ Serverless UI:

Step 6: Deploy to production

Once you are satisfied with your changes, you can merge your branch into main and the changes will be deployed to your production Serverless deployment.

Next steps

Congratulations! You've just built and run your first pipeline with Dagster. Next, you can: