rafal-kucharski / XMLParserProductImages

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

XML Parser Product Images

Laravel application to generate product images with title and price, based on an XML product feed.

Installation

  1. Clone the repository:
git clone git@github.com:rafal-kucharski/XMLParserProductImages.git laravel-product-image-generator
  1. Change to the project directory:
cd laravel-product-image-generator
  1. Build and run the Docker container:
docker-compose up --build -d
  1. Install the Laravel application dependencies:
docker-compose exec app composer install
  1. Copy the .env.example file to .env:
cp .env.example .env
  1. Generate the application key:
docker-compose exec app php artisan key:generate

Commands

To generate product images from an XML product feed:

docker-compose exec app php artisan generate:product-images [source]

Replace [source] with the path or URL to the XML product feed. If no source is provided, the default sample_feed.xml in the database/sources directory will be used.

Generated images will be saved in the storage/app/public/generated directory.

Testing

docker-compose exec app php artisan test
docker-compose exec app ./vendor/bin/phpstan analyse

About


Languages

Language:PHP 73.5%Language:Blade 25.7%Language:Dockerfile 0.6%Language:JavaScript 0.3%