---
title: Deploy Bagisto with AI on Blossom
url: "/deploy/bagisto/"
canonical_url: https://blossom88.com/deploy/bagisto/
markdown_url: https://blossom88.com/deploy/bagisto.md
summary: Set up a Bagisto store, order a product variant, and check which variant
  the order reserved.
categories:
- deployment
- commerce
stack:
- PHP
- Laravel
- Vue.js
- MySQL
---

# Deploy Bagisto with AI on Blossom

[Bagisto](https://bagisto.com/) is a Laravel commerce app with storefront
and admin screens. Try one order with a product variant so you can see
which item Bagisto sets aside.

## Ask Your Agent

> **Ask your AI agent:** Deploy Bagisto on Blossom with managed MySQL. Help me order a sample product variant and check its inventory.
>
> Follow this guide: https://blossom88.com/deploy/bagisto/

[Install the Blossom CLI and skill](https://docs.blossom88.com/learn/getting-started/install/) on your agent's machine and [choose a Location in your cloud account](https://docs.blossom88.com/learn/getting-started/choose-your-cloud/#connect-your-provider).

## Have Ready

- **Managed MySQL** (Required): Use an empty MySQL 8.4 database for the first setup.

## How It Runs

| Part | Role | Where |
|---|---|---|
| Bagisto | Serve the storefront and admin screens, with product images on a Volume | Persistent Service with Blossom Account access |
| MySQL | Store the catalog, orders, and variant reservations | Blossom Managed Data |

## Deploy Bagisto

Package the storefront and admin assets in a web image. Deploy it with a
Volume for `storage`, link managed MySQL, and enable Blossom Account access.

<details class="optional-reading" markdown="1">
<summary>Notes for your agent</summary>

Build from [Bagisto 2.5.1](https://github.com/bagisto/bagisto/releases/tag/v2.5.1)
using the [web Dockerfile](/deploy/recipes/bagisto/Dockerfile). Use MySQL 8.4,
`BAGISTO_MYSQL_URL` and a stable `APP_KEY`. Mount the Volume at
`/var/www/bagisto/storage`. Set `FILESYSTEM_DISK=public` for product media.

Run the [startup command](/deploy/recipes/bagisto/start-with-linked-data.sh)
on port 80 with a TCP health check. It maps the Link to `DB_URL` and uses
the generated HTTPS Service URL as `APP_URL`. For a private demo, use the
log mailer and set a sample From address and your private admin address.

</details>

<details class="optional-reading" markdown="1">
<summary>Commands your agent runs</summary>

    blossom app_plan:preview --data bagisto-plan.yml
    blossom database_instance:create --data bagisto-mysql.yml
    blossom app:create --data bagisto-app.yml
    blossom environment:create --data bagisto-environment.yml
    blossom environment_link:create --data bagisto-mysql-link.yml
    blossom env_var:push --environment environment-100 --file bagisto.env
    blossom service:create --data bagisto-web.yml
    blossom environment:deploy --id environment-100 --follow

</details>

## Set Up the Private Store Owner

Initialize the empty database once and create a private owner sign-in.
Open the storefront and sign in to the admin area.

> **Ask your AI agent:** Set up my private Bagisto owner account and make sure the storefront and admin area load.

> Follow this guide: https://blossom88.com/deploy/bagisto/



<details class="optional-reading" markdown="1">
<summary>Notes for your agent</summary>

Use the [one-time setup helper](/deploy/recipes/bagisto/prepare-store.php)
from the app directory with `BAGISTO_OWNER_EMAIL` and
`BAGISTO_OWNER_PASSWORD` set as protected Environment variables. Use
[Bagisto's release upgrade procedure](https://devdocs.bagisto.com/getting-started/upgrade-guide.html)
on established databases.

</details>

## Order One Variant

Add the **Harbor Workshop Kit** as a configurable product with a cover
image and stock for its variants. Choose one variant and place a sample
Cash on Delivery order. Check the order and its inventory reservation.

![Choose a workshop kit variant.](/deploy/assets/images/bagisto/bagisto-workshop-kit.webp)

> **Ask your AI agent:** Add a sample workshop kit with two variants, order one using Cash on Delivery and check which variant was reserved.

> Follow this guide: https://blossom88.com/deploy/bagisto/



## Keep It Running

![Reopen the original variant order.](/deploy/assets/images/bagisto/bagisto-variant-order.webp)


Replace the demo Container with the same storage and MySQL Link. Sign
in again and reopen the original order, variant reservation and image.

> **Ask your AI agent:** Replace the Bagisto demo Container, then reopen the same order and check its variant reservation and product image.

> Follow this guide: https://blossom88.com/deploy/bagisto/



<details class="optional-reading" markdown="1">
<summary>Commands your agent runs</summary>

    blossom service:scale --id service-100 --desired-size 0 --follow
    blossom service:scale --id service-100 --desired-size 1 --follow
    blossom container:list --service service-100

</details>

## What You Get

- A private storefront and admin area
- A configurable product with an image and a variant to choose
- A test order with one unit reserved for the selected variant
- An order and product image you can reopen after a deployment

Tested on Blossom: One offline order reserved the selected variant. After Container replacement, the order, reservation and product image matched the originals.
