Install Light
Install Light 0.18 in a Mage-OS or Magento Open Source shop from packages.disrex.nl, add Returns or rate tables, update, and what to check afterwards: the doctor, stock and locations, two-factor sign-in.
Light ships as Composer packages on packages.disrex.nl. One metapackage installs the whole admin. This page takes a shop from nothing to Light 0.18, with the commands the install tests ran on Mage-OS 3.5, Magento 2.4.9 and a live Hyvä shop on Magento 2.4.8-p5. Every release since is checked to resolve from packages.disrex.nl on those three platforms.
Every command below is composer … or bin/magento …. On a RollDev environment use roll composer … and roll magento …, which run the same command in the PHP container.
Requirements
| What | Version |
|---|---|
| Platform | Mage-OS 3.x (3.5.0 tested) or Magento Open Source 2.4.8 or 2.4.9 (2.4.8-p5 and 2.4.9 tested). Not Adobe Commerce |
| PHP | 8.3, 8.4 or 8.5 (8.4 and 8.5 tested) |
| Composer | 2 |
| Storefront | Luma, or Hyvä with the -hyva metapackage (Hyvä 1.4 and 1.5 tested) |
| Inventory | Optional. Without Magento's inventory modules (MSI), or with MSI and one source, Light keeps one quantity per product. Locations and pickup at a location need MSI (Stock and locations) |
| Two-factor sign-in | Optional. Light works with Magento_TwoFactorAuth on or off (Two-factor sign-in) |
| Access | A user and token for packages.disrex.nl |
Light needs nothing from the storefront theme, so it installs on any of these shops. Its own dependencies come along: disrex/module-ai, disrex/module-ai-shop-context and disrex/module-ai-catalog from packages.disrex.nl, mollie/magento2 ^3.1.4, paynl/magento2-plugin ^4.0 and dompdf/dompdf from Packagist.
Mollie 2 moves to Mollie 3
Light's Mollie bridge needs mollie/magento2 ^3.1.4. A shop on Mollie 2 gets Mollie 3 with the install when you add -w to the require; if the shop's own composer.json requires mollie/magento2 at ^2, require 'mollie/magento2:^3.1.4' in the same command as well. Mollie's Hyvä compatibility module 2.6 accepts Mollie 3, but test the checkout with every Mollie method the shop uses before you go live.
What you install
| Package | Holds |
|---|---|
magerex/distribution-nl | Light core (Light, AI, Apps, Catalog, Content, Customers, Discounts, Documents, Home, Locations, Orders, Settings, Themes), the bundles pack mrx/module-product-bundles, the group pages pack mrx/module-product-group-pages and the downloads pack mrx/module-product-downloads, the Dutch pack mrx/module-country-nl, the Mollie and Pay. bridges, the Mage-OS SEO bridge mrx/module-seo-mageos and MageRex Support: 21 Light modules. It requires all 21 packages, mrx/module-locations among them; that one stays off on a shop without MSI (Without MSI) |
magerex/distribution-nl-hyva | magerex/distribution-nl plus the Hyvä storefront parts of Content, Discounts and Settings: 24 Light modules |
mrx/module-returns | Returns, an add-on. It is in neither metapackage; magerex/distribution-nl suggests it (Returns) |
magerex/light-branding | The MageRex brand: logo, favicon, sign-in page and the Baken default theme, an add-on. It is in neither metapackage, so a metapackage install is white-label (The MageRex brand) |
mrx/module-christmas | A Christmas theme for the admin with lights, snow, a reindeer and Santa Claus, with one switch per effect on Settings > Appearance, an add-on. It is in neither metapackage; magerex/distribution-nl suggests it (Christmas) |
mrx/module-shipping-matrixrate | Rate tables by destination, weight, order amount or number of items, an add-on on top of webshopapps/module-matrixrate. It is in neither metapackage (Rate tables) |
magerex/light-demo-data | Demo products, customers and orders for a demo shop. Separate, never on a live shop |
Packages and compatibility lists every package, which ones install on their own, what a shop may leave off and the bridges to other modules.
Access to packages.disrex.nl
Store the credentials once per machine, in Composer's global auth.json:
composer config --global http-basic.packages.disrex.nl <user> <token>Leave out --global to write them to the project's auth.json instead. Keep that file out of git.
The repository
A shop that doesn't know packages.disrex.nl yet adds it, limited to Light's vendors so it never serves another package:
composer config repositories.disrex '{"type":"composer","url":"https://packages.disrex.nl/","only":["mrx/*","magerex/*","disrex/*"]}'Use composer config, not a hand edit or jq: a shop's repositories can be a list or an object, and composer config writes either.
A shop that has packages.disrex.nl already (every Disrex shop) keeps its entry and adds an exclude for Mollie and Pay.: packages.disrex.nl holds old copies of both (Mollie 2.49, Pay. 4.0.7) that would hide the current releases on Packagist, and Light's Mollie bridge needs Mollie 3. In composer.json, the entry then reads:
"disrex": {
"type": "composer",
"url": "https://packages.disrex.nl/",
"exclude": ["mollie/*", "paynl/*"]
}First install
composer require 'magerex/distribution-nl:^0.18'
bin/magento module:enable Mrx_Light Mrx_Ai Mrx_Apps Mrx_Catalog Mrx_Content Mrx_Customers \
Mrx_Discounts Mrx_Documents Mrx_Home Mrx_Locations Mrx_Orders Mrx_Settings Mrx_Themes \
Mrx_ProductBundles Mrx_ProductGroupPages Mrx_ProductDownloads Mrx_CountryNl Mrx_PaymentsMollie Mrx_PaymentsPaynl Mrx_SeoMageos \
MageRex_Support \
Disrex_Ai Disrex_AiShopContext Disrex_AiCatalog Mollie_Payment Paynl_Payment
bin/magento setup:upgrade
bin/magento cache:flushRun setup:upgrade straight after composer require, and module:enable before it. Until it has run, the database is behind the code, and Magento's admin stops with its "Please upgrade your database" error.
For a Hyvä shop, require 'magerex/distribution-nl-hyva:^0.18' instead and add Hyva_CompatModuleFallback Mrx_ContentHyva Mrx_DiscountsHyva Mrx_SettingsHyva to the module:enable line: the three Light Hyvä modules need Hyvä's compat-module fallback, which the Hyvä theme module doesn't enable on its own.
-w: on a shop that already locks some of Light's dependencies at older versions (Mollie 2, for one), add-wto the require so Composer may update those as well; without it the require stops on the conflict. If the shop's owncomposer.jsonrequiresmollie/magento2, require'mollie/magento2:^3.1.4'in the same command.module:enablenames every module the metapackage brings, with the five it needs from other vendors (Disrex_Ai,Disrex_AiShopContext,Disrex_AiCatalog,Mollie_Payment,Paynl_Payment):module:enablerefuses a module whose required packages' modules are off. Name them all.module:enablewrites every module on disk intoapp/etc/config.php, and one that isn't listed there yet and isn't named goes in as0, disabled. Without themodule:enablestep,setup:upgradeenables every module thatconfig.phpdoesn't list yet, and that is how the install tests ran; it leaves a module thatconfig.phplists as0off, which naming it fixes. The admin is white-label: it shows the platform's own logo until you add the MageRex brand.setup:upgradecreates Light's tables, runs its data patches and prints the compatibility gate's line:Light API 0.18.0: every module that extends Light is in range.Any other line names the module that is out of range.
No --keep-generated on the first install
Run the first setup:upgrade without --keep-generated, even when your deploy script passes it. With the flag, Magento runs the new modules' data patches with the DI configuration from before they were enabled. In 0.1.1 and earlier this failed in the Dutch pack's shipping zones and left every new module disabled; from 0.1.2 those steps wait for the next setup:upgrade. Later upgrades may use the flag.
In production mode, compile and deploy as for any new module, after setup:upgrade:
bin/magento setup:di:compile
bin/magento setup:static-content:deploy
bin/magento cache:flushIn developer mode, skip the compile: developer mode builds generated code on demand.
Hyvä shops
The -hyva modules add templates and Tailwind classes to the storefront. Let Hyvä list them, then run your Hyvä theme's Tailwind build:
bin/magento hyva:config:generateHyvä code in a -hyva module explains what the build picks up.
Check the install
bin/magento module:status --enabled | grep -cE '^(Mrx|MageRex)_'
bin/magento mrx:light:doctorThe count is 19 for magerex/distribution-nl, 22 for magerex/distribution-nl-hyva, and one more for each add-on: Returns, rate tables, the Flex bridge, the MageRex brand and Christmas (mrx/module-christmas). Before 0.5.0 it was 17 and 20, without the two product packs. From 0.2.0 to 0.4.8 it was 18 and 21, with MageRex_Branding in the metapackage.
The doctor, mrx:light:doctor, checks Light and every module that extends it: ranges, pools, routes, layout, the second factor, email templates. It ends with 0 errors, and exits with 1 when it finds one, so a deploy script can stop on it. Findings about modules that don't extend Light show as one summary line and never fail it; --all lists them, and --module=<Vendor_Module> checks one module, a pack or your own bridge (Doctor rules). Run it after the install, after every update, and after you install or update a module that extends Light.
What changes on an existing shop
- The admin. Every admin user works in Light's simple mode by default. "Switch to advanced mode" opens the stock admin, per admin user.
- Emails and PDFs. Installing Light changes nothing your customers receive. A shop that has another vendor's documents module (a PDF customiser, an email attachment extension) or its own theme emails keeps sending them until the merchant chooses Light's on Settings > Emails & documents. The Home setup guide shows the step "Choose your emails and documents" until the first save, and the card names the templates and modules it found. Disrex provisioning saves the choice for a merchant; the install never does.
- After the merchant chooses Light's PDFs. Light's Documents module makes the invoice, credit memo and packing slip PDFs, also from Magento's own print buttons. Modules that plug Magento's PDF classes stop showing their changes; the card names them (Plugins on the stock PDF classes).
- After the merchant chooses Light's emails. Order, invoice and shipment mails get Light's layout. A template the owner saved in Marketing > Email Templates keeps winning.
- Light's own emails and PDFs. What the shop never had before Light (order canceled, shipping update, invites, the order PDF, the picklist, the return slip) is Light's from the install. Two details: Local pickup is Light's own only on a shop without MSI's store pickup modules (with them, its ready-for-pickup email replaces a stock one and follows the choice), and the return slip rides on the approval mail only once the shop uses Light's PDFs.
- Hyvä storefront. Mrx_SettingsHyva shows the store's welcome text in a bar above the header. It stays hidden while the text is empty or Magento's default.
Stock and locations
Light reads stock the way the shop keeps it. Three cases, and MSI stays the default and the recommended setup for a new shop, because pickup at a location needs it:
- With MSI and one source (most shops): simple mode. Every product has one quantity, and Settings > Locations shows the business address as the one location, with "Add location". Nothing on the other screens says location. Local pickup is Light's own carrier at the business address.
- A second location turns on locations mode. The merchant's first "Add location" makes the business address the first location, copies its stock there and keeps every channel selling the same quantities; then stock per location shows on products, the Stock page and the Ship dialog, and pickup at a location runs on Magento's In-Store Pickup. There is no way back to simple mode, so take a database backup before the first "Add location". On a shop above 3,000 products the copy runs in the cron job
mrx_locations_conversion, so cron must run. The VIES recheck on Settings > Taxes runs in the cron jobmrx_customers_vies_rechecktoo. - Without MSI (the inventory modules disabled, or their packages removed) every product has one quantity in Magento's own stock item, and there are no locations: Settings > Locations is absent and Local pickup is Light's own carrier at the business address.
Mrx_Locationsstays off. Disable it together with theMagento_Inventory*modules, because Magento refuses to disable them while it is on; on a shop that removed the packages it doesn't register (Without MSI).bin/magento mrx:light:doctor --allnames the mode understock_mode.
A shop that already keeps stock at several MSI sources opens in locations mode. Locations and pickup explains both modes for module developers.
Without MSI
Only Mrx_Locations names MSI types, so every other Light module installs, compiles (setup:di:compile) and runs on a shop whose MSI packages are gone. Mrx_Locations registers only while every MSI package its classes name is on disk (the core inventory packages and In-Store Pickup). On a shop without them it never registers, setup:upgrade drops it from app/etc/config.php, and the compiler never reads it. magerex/distribution-nl still requires mrx/module-locations: one metapackage serves both kinds of shop, and the root replace below satisfies the inventory packages it requires.
To remove the packages, add them to the replace of the shop's root composer.json, each with the version "*". Two sets of names:
- the 76
magento/*names ofyireo/magento2-replace-inventory(everymagento/module-inventory-*, plusmagento/inventory-composer-installerandmagento/inventory-composer-metapackage). Runcomposer replace:bulk:add yireo/magento2-replace-inventoryfromyireo/magento2-replace-tools, which copies them intoreplace. Do notcomposer requirethe bulk package; - on Mage-OS, also the 77
mage-os/*names that the lock holds:jq -r '.packages[].name | select(test("^mage-os/(module-inventory|inventory-)"))' composer.lock. Yireo's list doesn't cover them, and Mage-OS's own product package requires two of them by that name (mage-os/inventory-metapackageandmage-os/module-inventory-reservations-grid). Keepmage-os/module-catalog-inventory,-catalog-inventory-graph-ql,mage-os/module-grouped-catalog-inventoryandmage-os/module-sales-inventory: they are Magento's own stock.
Then follow yireo's procedure:
rm -r vendor/
composer update --lock
rm -r generated/
bin/magento setup:di:compile
bin/magento setup:upgradeRun bin/magento mrx:light:doctor --all: stock_mode says "Magento's own stock". The MSI tables stay in the database as orphans, and nothing reads them. The shop has one global stock: per-channel stock ("Sold out in" a channel) needs MSI and does not show.
Removing only part of MSI, for example the pickup packages with locations still wanted, is not supported. Mrx_Locations stays off, and the doctor warns stock_mode that part of MSI is missing. A shop that already runs on MSI and has open orders needs the steps below first.
Removing MSI from a running shop
Removing MSI from a shop with open orders can sell stock twice. MSI lowers a product's quantity when the order ships, not when the customer orders: until then it keeps a reservation in inventory_reservation. Magento's own stock lowers the quantity the moment the customer orders. Remove MSI and the reservations go with it, while the quantities still hold the stock of every order that hasn't shipped. Those items show as available again and the shop can sell them a second time.
A new shop, or a shop without open orders, has nothing to fix. Otherwise, before you remove MSI:
- Ship every open order, or
- lower each product's quantity by what its open orders hold. "Available to sell" on the Stock page shows the number to keep while MSI is still on.
Take a database backup first: setup:upgrade drops the MSI tables once the packages are gone.
Two-factor sign-in
Light follows Magento_TwoFactorAuth. While it is on, Light shows nothing of the admin (no menu, no counts, no store name) until the second factor is done, and every light/* request refuses a half-signed-in session. Each role Light makes (the Staff and Shipping staff presets, roles from Light's role editor) holds Magento_TwoFactorAuth::tfa, so staff can set up and use their own second factor. setup:upgrade gives that resource to existing roles that hold Mrx_Light::light, also one made in Magento's own role editor with Light ticked.
A module that switches the second factor off without granting the two-factor session (MarkShust_DisableTwoFactorAuth, WolfSellers_EnableDisableTfa) keeps every Light page on the two-factor screen; the doctor warns with tfa_bypass (Light keeps sending you to the two-factor screen). Keep the second factor on a live shop.
The setup guide
Home shows a setup guide of eight steps until each is done: a first product, business details, a logo, payments, shipping, taxes, a test order and the legal pages. Two more steps come from other modules: the order numbers and "Choose your emails and documents". The last one stays open on every shop, also one with another vendor's documents, until the merchant keeps the shop's emails and PDFs or switches to Light's and saves; nothing changes for customers before that. On a shop that already sells, most steps are done at once. What the install tests met:
- Business details is done once no sender address is an example such as
owner@example.com. The page flags such a sender. - Payments counts a method only when its provider is connected, as Settings > Payments shows it. Mollie and Pay. need the shop's own keys.
- Shipping is done once a zone has a rate, or local pickup is on.
- Taxes: the Dutch VAT card on Settings > Taxes sets up 21%, 9% and 0%. A shop that charges Dutch VAT already counts as set up, and the card leaves its rates, rules and classes as they are.
- Test order: place one on the storefront; on a local shop, set up mail first (Mail in a local RollDev shop).
- Choose your emails and documents is done once the merchant saves the choice on Settings > Emails & documents, whichever way it goes. Installing Light on a shop with another vendor's documents module leaves that shop's emails and PDFs alone until then. Add this step to your own setup checklist when you hand a shop over: open the card, read what it found, and choose.
Bundles and group pages
Two packs add kinds of product to the product editor. mrx/module-product-bundles (Mrx_ProductBundles) makes bundles, several products sold together for one price. mrx/module-product-group-pages (Mrx_ProductGroupPages) makes group pages, separate products shown together on one page and paid for separately. Both come with magerex/distribution-nl and magerex/distribution-nl-hyva, and both are on in the module:enable line of the first install. With either installed, the product list has a "Sell products together" button and "Add product" has a quiet link that goes to the choice between the kinds, or straight to the one pack's form when only one is on (Add a kind of product).
A shop may leave them off. Take them out of the module:enable line on the first install, or run bin/magento module:disable Mrx_ProductBundles Mrx_ProductGroupPages before setup:upgrade. Neither pack has tables, so disabling one drops nothing. Light then has no button and no link, and a bundle or group page the shop already has opens read-only with a link to the advanced view. The storefront and the orders keep working, because Magento owns them. bin/magento mrx:light:doctor warns product_kind_pack while products of such a type exist and their pack is off. A pack also stays out by itself on a shop without Magento's bundle or grouped product module.
Digital downloads
mrx/module-product-downloads (Mrx_ProductDownloads) makes digital downloads: products the customer gets as a file, such as an e-book or a pattern, on Magento's downloadable product. It comes with both metapackages and is on in the module:enable line of the first install. It is a kind of product but not one of the "Sell products together" kinds: the merchant reaches it from "Add product" (a line that shows while "This is a physical product" is off), from the palette ("New digital download") and from the stock "Add Product > Downloadable Product". The order page gets a Downloads card that says whether the customer can download yet.
Magento's own settings stay in charge (Stores > Configuration > Catalog > Downloadable Product Options): the files unlock once the order is invoiced, and guests can't buy downloads, by default. A file can also be a web address, but only on a domain in downloadable_domains in app/etc/env.php; add one with bin/magento downloadable:domains:add cdn.example.com. Light reads that list and never writes it.
A shop may leave the pack off (bin/magento module:disable Mrx_ProductDownloads before setup:upgrade). It has no tables. Light then opens a digital download with its price and stock, and its files are changed in the advanced view. The doctor warns product_kind_pack. The pack also stays out by itself on a shop without Magento's downloadable module.
Returns, an add-on
Returns is not part of either metapackage. Add it when the shop takes returns:
composer require 'mrx/module-returns:^0.18'
bin/magento setup:upgradeIt brings mage-os/module-rma from Packagist (Mage-OS 3.x ships it already), which needs Magento_GraphQl and Magento_Webapi; a shop that removed them can't install it, and Adobe Commerce has its own returns module. A shop that disabled packagist.org in its composer.json adds it back for this package. Return mails go out only while "Accept return requests" is on in Settings > Returns.
To take Returns out, disable both modules before you remove the package, then remove it:
bin/magento module:disable Mrx_Returns MageOS_RMA
composer remove mrx/module-returns
bin/magento setup:upgradeDump the database first. A setup:upgrade that runs while the modules are disabled and their code is still installed drops the rma_* tables, returns included. Once the code is gone, setup:upgrade leaves the tables and the returns in them alone. Removing the package without disabling the modules first leaves every bin/magento command failing until the cache storage is cleared (Updating).
Rate tables, an add-on
Light's shipping zones set a price per group of countries, by weight, free above an amount. For prices by region or postcode, or in steps by order amount or number of items, add the rate table pack. It is in neither metapackage:
composer require 'mrx/module-shipping-matrixrate:^0.18'
bin/magento module:enable WebShopApps_MatrixRate Mrx_ShippingMatrixrate
bin/magento setup:upgrade
bin/magento cache:flushIt brings webshopapps/module-matrixrate 20.5 (MatrixRate) from Packagist; packages.disrex.nl holds no copy of it, so the repository entry needs no exclude for it. A shop that disabled packagist.org in its composer.json adds it back for this package. Settings > Shipping and pickup then asks "How do you charge shipping?", per channel: Shipping zones or Rate table. The zones stay stored while the rate table charges. bin/magento mrx:light:doctor --module=Mrx_ShippingMatrixrate prints "No problems found." The pack's README has the rest.
Disabling MatrixRate deletes every rate
MatrixRate keeps its rates in the table webshopapps_matrixrate. Disabling WebShopApps_MatrixRate, also on the way to removing it, drops that table on the next setup:upgrade, every rate included. Export the rates first (Export CSV in the menu beside "Import my zones" on the Rate table page) and back up the database. Before you remove the pack, switch Settings > Shipping and pickup back to Shipping zones: the switch lives in the pack, and without it the zones stay folded while MatrixRate is installed.
Flex shops, an add-on
A shop that runs Disrex Flex (Disrex_FlexCore, Hyvä only) adds the Flex bridge. It is in neither metapackage:
composer require 'magerex/module-flex-bridge:^0.18'
bin/magento module:enable MageRex_FlexBridge
bin/magento setup:upgrade
bin/magento cache:flushLight's Home, Content > Pages, the page editor and the category and product editors then open the Flex Editor in a new tab. Without FlexCore the package shows nothing and its URLs answer 404. A custom role that held Content before the install has no rule for the editor: open it in Settings > Users and permissions and save it once. The package's README has the rest, such as which store view opens.
The MageRex brand, an add-on
A metapackage install shows the platform's own logo and theme: Mage-OS on Mage-OS, Magento on Magento Open Source. For the MageRex logo, favicon, sign-in page and the Baken default theme, add the brand package. It is in neither metapackage:
composer require 'magerex/light-branding:^0.18'
bin/magento module:enable MageRex_Branding
bin/magento setup:upgrade
bin/magento cache:flushA theme an admin picked, and a store default someone saved, stay as they are; the brand sets the default only where none was saved. An own logo uploaded in Settings beats the brand's. To take the brand out, composer remove magerex/light-branding and run setup:upgrade: it keeps no data, and the admin shows the platform's brand again. A branding package shows how to make one for your own agency.
Christmas, an add-on
mrx/module-christmas adds a Christmas theme to the admin: Christmas red, pine green and gold, and effects while the theme is in use: lights, baubles, snow, a reindeer and sleigh, presents and a Santa Claus (with a hat) as the name in the top bar. It is a theme like the others, so each admin chooses it for themselves; nobody else, no storefront page and no email changes. It is in neither metapackage:
composer require mrx/module-christmas:^0.18
bin/magento module:enable Mrx_Christmas
bin/magento setup:upgrade
bin/magento cache:flushEach admin opens Settings > Appearance, chooses "Christmas" in "Your theme" (or as the dark theme of automatic mode, or from the user menu), and then switches off the effects they don't want in the "Christmas effects" card, which shows while the Christmas theme is chosen; each switch saves at once. The effects run only while the theme is in use and stop when another theme takes over. The choices sit on the admin's own user row (admin_user.extra), so composer remove mrx/module-christmas needs no clean-up; an admin who still has the theme falls back to the store default.
Updating
composer update 'mrx/*' 'magerex/*' -w
bin/magento setup:upgrade
bin/magento cache:flushFrom 0.4.8 or earlier: keep the MageRex brand
0.4.9 took magerex/light-branding out of magerex/distribution-nl. A shop that has the brand only through the metapackage loses it on the update, and its admin shows the platform's own logo. To keep the brand, require it in the same command: composer require 'magerex/distribution-nl:^0.4' 'magerex/light-branding:^0.4' -w (From 0.4.8 to 0.4.9).
-w updates the Light packages and the packages they need, and leaves the packages your shop requires itself, such as its own payment plugin, at their locked versions. When Composer says a package your shop requires is in the way, use -W, which updates those too; check what it changed before you deploy.
composer update stays inside the range in the shop's composer.json. That is enough for a patch (0.18.0 to 0.18.1), but a shop that required ^0.17 never reaches 0.18.0 that way: a caret on 0.x stops at the next minor. Move the range with a require, for every Light package the shop requires itself:
composer require 'magerex/distribution-nl:^0.18' -w
bin/magento setup:upgrade
bin/magento cache:flushAdd 'mrx/module-returns:^0.18' and 'mrx/module-shipping-matrixrate:^0.18' to the same require when the shop has them, and use magerex/distribution-nl-hyva on a Hyvä shop. From 0.1.x, setup:upgrade creates mrx_location, mrx_location_stock and mrx_order_pickup and enables Mrx_Locations, which comes in with the update. A module of your own that extends Light moves its ranges too (Upgrading from 0.14.x to 0.17.0, from 0.13.x to 0.14.0, from 0.12.x to 0.13.0, from 0.11.x to 0.12.0, from 0.10.x to 0.11.0, from 0.9.x to 0.10.0, from 0.8.x to 0.9.0, from 0.7.x to 0.8.0, from 0.6.x to 0.7.0, from 0.4.x to 0.6.0, from 0.3.x to 0.4.0). Run setup:upgrade right after composer: between the two the admin is unusable. Composer has put the new code next to a database that doesn't know it, and a module that comes in with the update, such as Mrx_Locations from 0.2, is still off. Light's Home then fails with "Cannot instantiate interface Mrx\Locations\Api\LocationsInterface" until setup:upgrade enables it.
After the update, run bin/magento mrx:light:doctor: it names a module whose Light range no longer matches.
In production mode, run setup:di:compile and setup:static-content:deploy after setup:upgrade, as on the first install. Run setup:upgrade on every update, even a patch: 0.1.2 adds four database indexes for the orders, customers and Home screens, and only setup:upgrade creates them. On a large shop that first run takes longer while MySQL builds them. Changelog lists what each release changed.
From 0.1.0: decide about Returns before you update
0.1.1 took mrx/module-returns out of magerex/distribution-nl. A shop that installed 0.1.0 has Returns only through the metapackage, so composer update removes mrx/module-returns and mage-os/module-rma while Magento's cache still lists both modules. Every bin/magento command then fails with Class "MageOS\RMA\Console\Command\CleanupCommand" does not exist, setup:upgrade and cache:flush included, until the cache storage is cleared by hand (var/cache, or the Redis or Valkey cache database). Before you update:
- To keep returns, run
composer require 'mrx/module-returns:^0.18'. - To drop them, dump the database and run
bin/magento module:disable Mrx_Returns MageOS_RMA, then update straight away. Therma_*tables stay in the database: Magento drops them only when asetup:upgraderuns while the modules are disabled and their code is still there.
Upgrading from 0.1.0 to 0.1.1 has the details.
Mail in a local RollDev shop
A new RollDev shop on Mage-OS 3.5 or Magento 2.4.9 sends no mail: the PHP image's sendmail command is one that the Symfony mailer refuses ("Unsupported sendmail command flags"), so an order confirmation fails with "Unable to send mail" while the order itself goes through. Send mail over SMTP to RollDev's mail catcher instead:
bin/magento config:set system/smtp/transport smtp
bin/magento config:set system/smtp/host mailhog
bin/magento config:set system/smtp/port 1025Mail then lands in https://mailhog.roll.test/. This is for a local shop only.
Troubleshooting
- Every Light module is disabled after the first
setup:upgrade. It ran with--keep-generatedon 0.1.1 or earlier. Enable them again (bin/magento module:enablewith the names fromapp/etc/config.php, or put that file back) and runsetup:upgradewithout the flag. - The doctor reports findings. Doctor rules explains each rule and its fix.
- Light pages keep sending you to the two-factor screen. A module skips the second factor without granting it (Light keeps sending you to the two-factor screen).
- A module's Light parts are gone, or a red banner names a module. Its Light API range doesn't match (A module's Light parts are gone).
- A Hyvä storefront part doesn't show. Run
hyva:config:generateand the Tailwind build again (A storefront change of a -hyva module doesn't show). - Composer stops on another repository with HTTP 401. A private repository of the shop, such as Hyvä's Private Packagist, needs its own credentials in
auth.json; that isn't Light's. - A product save logs OpenSearch 403 errors on a new local shop. OpenSearch blocks index creation when the Docker disk is nearly full. Free disk space, then run
bin/magento indexer:reindex. - Anything else: Troubleshooting.
Last updated on