PoC of Shopify development workflow using GitHub Actions with multiple environments.
This is a Proof of Concept of workflow with different environments using Github and GitHub Actions.
Pre-requisites :
We’re using 2 stores for our workflow with multiple themes :
master
(for production theme on production environment)preprod
(for pre-production theme on production environment)develop
(for staging theme on development environment)Production and staging store have same configuration. But we often have the same content between the two environments.
Workflow is pretty simple, based on GitFlow but with no release branch nor tags.
master
, preprod
and develop
branches are protected. It’s not possible to push directly on them.
The best way is to use pull requests.
master
(eg. feature/store-locator
)fix/
for a fix or feature/
for a new featurefeature/store-locator
into develop
feature/store-locator
into preprod
feature/store-locator
into master
New branch always start from master
one, even if the purpose is a new feature or a fix.
We’re using Theme Kit for local developers : https://shopify.github.io/themekit/
We created a template on development store for each developer.
Workflow files are available here.
They used the Deploy Shopify theme Actions : https://github.com/marketplace/actions/deploy-shopify-theme
First you have to generate a private app to get an API KEY on Shopify. Get API Access.
Then you’ll need to provide some secrets :
demo-staging.myshopify.com
).demo.myshopify.com
)../
.The Dockerfile and associated scripts and documentation in this project are released under the MIT License.