Module adds command to dump media product images with some limitations:
- Selective products SKUs
- Total max products images size
It allows you to make convenient-size data snapshots for project/developers/CICD processes. You can filter only needed products including various products types or limit total images weight to given size.
composer require orba/module-sample-data
bin/magento setup:upgrade
bin/magento orba:sampledata:media [--skus=SKU1,SKU2,...] [--max-size=N] [--maintenance]
--skus=SKU1,SKU2,...
- Optional, filter comma separated SKUs--max-size=N
- Optional, allowes to limit aggregated size of product images to N (in MB).--maintenance
- Optional, enable maintenance mode
Result tgz file will be placed in var/backups
directory.
Complex product children will be attached into the dump too.
bin/magento orba:sampledata:media --skus=WJ10,WJ11,WJ12
In this case product images will be limited to 20MB.
bin/magento orba:sampledata:media --max-size=20
bin/magento orba:sampledata:media --skus=WJ10,WJ11,WJ12 --max-size=20
bin/magento orba:sampledata:media