This page assumes familiarity with Project Structure and CI/CD integration.
obproject-deploy, several resources are created on the platform. Understanding what gets created, and how to inspect or remove it, is essential for managing feature branches, cleaning up after experiments, and building custom deployment pipelines.
What a deploy creates
obproject-deploy reads your obproject.toml and processes the project directory in four stages:
Each resource is scoped to a project and branch. The branch is derived from your git ref (example: main becomes the production branch, feature-v2 becomes a test branch).
Branch naming
Branch names are normalized during deployment:-and/characters are replaced with_- The result is lowercased
feature/add-scoring becomes feature_add_scoring.
Workflow template IDs follow a specific format where underscores are stripped entirely:
fraud_detection on branch main with a flow called TrainFlow:
feature-v2:
prod / test.{branch} prefix is Metaflow’s @project branch convention.
Deployment lineage tags
Every flow deployed byobproject-deploy 0.2.35 or later is automatically tagged with the commit it was built from and the CI run that deployed it. These tags attach to the Argo workflow template and propagate to every run, so you can trace any running workflow back to a specific commit and CI build.
What you’ll see on each deployed run:
commit-hash:<sha>: the source commit being deployed (always).merge-commit-hash:<sha>: only on PR builds where CI synthesizes a merge commit distinct from the source.- A provider-named CI run tag, such as
obproject-deploy-gh-action-run:12345for GitHub Actions,obproject-deploy-circleci-run:678for CircleCI, etc.
obproject.toml:
Controlling what gets deployed
By default,obproject-deploy deploys all flows, apps, and assets on every branch. This can lead to unnecessary app deployments on feature branches that persist after merge. Two mechanisms let you control this.
Per-component branch filtering
Place anobproject_deploy.toml in any deployments/<app>/ or flows/<flow>/ directory to declare which branches should deploy that component:
obproject_deploy.toml is present, the component deploys on all branches (backward compatible). On non-main branches, an info message suggests adding the file.
Your CI workflow stays simple; just call obproject-deploy, and the filtering happens automatically based on the config files checked into the repo.
CLI flags
For ad-hoc control without config files, use these flags:Inspecting deployed resources
Use theouterbounds flowproject CLI to inspect what’s currently deployed.
List workflow templates
View metadata
obproject-deploy run.
Tearing down a branch
When a feature branch is merged or abandoned, useteardown-branch to clean up all its deployed resources:
- Workflow templates: cascade-deletes associated CronWorkflows and Sensors
- Data assets
- Model assets
- Apps (capsules)
- Flowproject metadata
prj.asset.delete_data_asset() from a flow step, as described in Project assets.
Promoting assets before teardown
Teardown deletes asset metadata (the catalog entries), not the underlying data. If a feature branch trained a model or produced a dataset you want to keep onmain, you need to promote those assets before tearing down the branch.
promote_assets() reads every asset on the source branch, takes the latest instance of each, and re-registers it on the target branch with the same blob references, annotations, and tags. The underlying S3 objects are not copied; only the metadata pointer is created.
promoted_from_branch, promoted_from_instance) so you can trace where the production asset originated. With with_aliases=True, any aliases set on the source branch (such as @champion or @validated) are recreated on the target branch pointing to the promoted instance.
Automating teardown in CI/CD
Add a teardown step to your CI/CD pipeline when branches are deleted or PRs are closed. If you want to preserve assets, add a promote step before teardown:Building a custom deploy pipeline
If you need more control thanobproject-deploy provides, you can use the outerbounds flowproject commands directly. This is useful when you want to:
- Deploy a subset of flows or assets
- Integrate with a non-standard CI/CD system
- Add custom validation steps between deploy stages
Registering metadata
After deploying flows and assets through your own tooling, register the metadata so the platform knows what’s deployed:Deleting metadata only
If you manage resource lifecycle separately and only need to clean up the metadata record:This does not touch workflow templates, assets, or apps.