Deploying to Tinybird using the CLI¶
You can deploy your data projects to Tinybird Cloud directly from the command line using the Tinybird CLI.
To deploy to Tinybird Cloud, create a staging deployment using the --cloud
flag. This prepares all the resources in the cloud environment.
Check the deployment¶
Before creating the deployment, you can check the deployment with the --check
flag. This runs a series of checks to ensure the deployment is ready. This is similar to a dry run.
# Checks the deployment tb --cloud deployment create --check
Create a staging deployment¶
Create a new staging deployment in Tinybird Cloud. Pass the --wait
flag to wait for the deployment to finish:
# Prepares all resources in Tinybird Cloud tb --cloud deployment create --wait
To run commands against the staging deployment, use the --staging
flag. For example:
tb --staging --cloud endpoint ls
Promote to live¶
When the staging deployment is ready, promote it to a live deployment in Tinybird Cloud:
# Enables the deployment in Tinybird Cloud tb --cloud deployment promote
To deploy and promote in one step, use the tb deploy
alias. For example: tb --cloud deploy
.
Next steps¶
- Learn more about deployments.
- Learn about datafiles, like .datasource and .pipe files. See Datafiles.
- Browse the Tinybird CLI commands reference. See Commands reference.