Shopify / hydrogen-demo-store

This template contains a full-featured setup of components, queries and tooling to get started with Hydrogen. It is deployed to https://hydrogen.shop
100 stars 34 forks source link

Set up Oxygen deployment workflow file #28

Open shopify[bot] opened 5 months ago

shopify[bot] commented 5 months ago

[!WARNING] If you've previously made customizations to your Oxygen workflow file, then this PR might overwrite them. Be sure to review all changes before merging.

Automatic deployments with Hydrogen and Oxygen

This pull request adds a workflow file that enables GitHub to automatically deploy your Hydrogen app each time you push or merge changes.

Pushes to your main branch deploy to your production environment. Pushes to any other branch deploy to your preview environment:

Git branch Environment URL
main Production https://storefront-1-58c76f821bf444728d78.o2.myshopify.dev
(All other branches) Preview {hash}.myshopify.dev

You can also create your own custom environments (like "Staging" or "QA") and assign them to your own custom domains.

Developing locally 💻

After you’ve cloned your project, install the dependencies and run the local development server:

npm install && npm run dev

Link your local development environment to your Shopify store to render your product inventory data:

npx shopify hydrogen link --storefront "Storefront 1"

Linking your project automatically keeps your local environment variables in sync with Oxygen, allows you to query your store data, and lets you create deployments from the command line at any time. Check the complete list of Hydrogen CLI for a complete list of features.

shopify[bot] commented 5 months ago
Oxygen deployed a preview of your shopify-setup-oxygen-workflow-k959 branch. Details: Storefront Status Preview link Deployment details Last update (UTC)
Hydrogen Demo Store v2 ✅ Successful (Logs) Preview deployment Inspect deployment April 18, 2024 1:57 AM

Learn more about Hydrogen's GitHub integration.