Navigation
  • Stitch >
  • Application Deployment

Application Deployment

Introduction

Stitch uses a deployment-based versioning scheme that allows you to group updates to your application and make them available to client applications at the same time. You can deploy a new version of your application with multiple deployment methods that each fit a particular development workflow. You can also review the historical state of your application based on the built-in deployment history log.

Concepts

Deployment Methods

You can deploy new versions of your application through the Stitch UI or one of multiple code-based deployment methods that each suit a particular development workflow.

Deployment Method Details
Stitch UI

Use This Method If

  • You want to use a browser-based GUI to develop and manage your Stitch app.

Deployment Pattern

For a detailed walkthrough, see Deploy from the Stitch UI

  1. Make changes in the UI that are saved in a draft state and not visible to client apps.
  2. Review all draft changes and then deploy them together through the Stitch UI.
Automatic GitHub Deployment

Use This Method If

  • You want to use a code-first approach to app development.
  • You want to use Git to version control your app.
  • You want to automatically deploy changes based on the master branch of a GitHub repository.

Deployment Pattern

For a detailed walkthrough, see Deploy Automatically with GitHub

  1. Host your exported application repository on GitHub.
  2. Add, remove, or modify configuration files in a local clone of the repository to specify your updated application.
  3. When you’ve made all the changes that you want to, commit them and push to the GitHub. Automatically deploy the most recent version of a specific branch.
Stitch CLI

Use This Method If

  • You want to use a code-first approach to app development.
  • You want to use a command line interface to manage and deploy your Stitch app.

Deployment Pattern

For a detailed walkthrough, see Deploy Changes with Stitch CLI

  1. Export a copy of your application to a directory of configuration files and download it to your computer.
  2. Add, remove, or modify configuration files in the directory to specify your updated application.
  3. When you’ve made all the changes that you want to, manually deploy them by importing the updated application directory.

Application Components

Stitch applications are composed of components like Functions, Triggers, Auth Providers, Services, and Values. A deployment consist of at least one new, updated, or deleted component.

Configuration Files

Stitch uses configuration files to define your application’s metadata and components. Every component is defined by its own configuration file and each type of component uses a distinct configuration file schema. The Stitch UI manages your application’s configuration files for you, but you can also use a code-based deployment method to update your application by adding, modifying, and deleting configuration files directly.

Application Directory

Stitch applications are structured in a nested directory format called an application directory that contains configuration files for your application components. The configuration files are grouped into directories based on their component type. You can download a copy of the application directory for the most recently deployed version of an app by exporting it from the Stitch UI or Stitch CLI; or by cloning the underlying Git repository.

For additional information on the structure of an application directory as well as the schema of each configuration file type, see Application File Schema.

Deployment History

Stitch logs every deployment of an application and exposes a list of the 100 most recent deployments in the History tab of the Deploy in the Stitch UI. Each deployment log includes data about a set of changes, such as their status, origin, and time of deployment.

If you choose to deploy through the Stitch UI, any changes you make are grouped in a row at the top of the deployment history table that represents draft changes made since the previous deployment. You can use the Action buttons on this row to manually deploy all draft changes.

The table of application deployment history logs in the Stitch UI