Deploy to Shopify

How to deploy to Shopify?

Deploying to Shopify is possible with three actions tailored for Shopify deployments. Whether you prefer automatic updates or your themes triggered by each push to a branch, manual deployment on click, or scheduled recurring deployments, Buddy offers a range of options to suit your deployment strategy.

Example pipeline with deployment to ShopifyExample pipeline with deployment to Shopify

Tip
If you are new to Buddy, check out our quickstart guides that will tell you how to build, test and deploy your type of application.

Configure pipeline in Buddy

  1. Create a new project in Buddy and synchronize your git repository:

Creating new projectCreating new project

  1. Add a new pipeline and configure the details: name, trigger mode, and a branch from which you want to deploy:

Adding new pipelineAdding new pipeline

Configure Shopify deployment

In your pipeline, click + and navigate to the Shopify section on the action list:

Shopify actionsShopify actions

Buddy offers 3 dedicated Shopify actions. The next steps depend on the action you select:

  • Shopify
  • Shopify CLI
  • Shopify Theme Kit

Shopify action configuration

This action uses only token-based Shopify integration. It's a basic action for Shopify deployment.

The action has four configuration tabs:

  • Transfer – here you select the Shopify integration, theme, source path, deployment flags, and files to ignore
  • Variables – here you can add and modify environment variables required by your workflow
  • Conditions – here you configure the trigger conditions for which the action will run
  • Options – here you define the action's name and behavior on failure and timeout

Shopify action configurationShopify action configuration

Tip
If you build your theme before Shopify action using a bundler such as Webpack or Vite, make sure to select Pipeline Filesystem as the source. If your theme is not in the root of your repository, change the path.

Shopify CLI action configuration

Shopify CLI is a command-line interface tool that assists in creating Shopify apps/templates. You can also use it to automate common development tasks while managing your online store.

The Shopify CLI action has been available in Buddy since 2023. To use it, you can use an integration based on either a token or an API key. For the API key authorization you need a Shopify partner token.

Shopify CLI replaces Theme Kit for most tasks related to theme development. You should use this action if you are working on Online Store 2.0 themes.

Shopify CLI action configurationShopify CLI action configuration

Hint
When using this action, it is worth adding the Lighthouse action to your pipeline for monitoring the performance of the website. Additionally, before deployment, you can perform a theme check and unit tests using the popular Vitest as a test framework.

Shopify Theme Kit action configuration

Theme Kit is a command-line tool designed for creating and managing Shopify themes. Currently, it is suitable for older themes than Online Store 2.0. This action uses only token-based Shopify integration.

Shopify Theme Kit action configurationShopify Theme Kit action configuration

Success
Buddy's deployment is based on changesets. This means only changed files are deployed, which makes it lightning fast ⚡️. The first deployment is always performed from scratch, unless you set a revision on the server in the Options tab. Get more details about automatic deployments to Shopify stores with Buddy from our guide.
Hint

đź“š Learn more about Shopify action features, integrations and alternatives.

Last update:
Sep 17, 2024