Key Hard is an educational project created to learn pipelines and deployment in IT.
It is based on an e-commerce shop selling software keys: agrochowski.pl
- Prestashop 1.7.8 - open-source e-commerce platform
- Docker - Application containerization system
- Docker Compose - Containerization management system
- Selenium - Library for building UI tests
All scripts are intended to be run from the repository root directory.
- Docker and Docker Compose installed
- Python 3.14+ (or use uv package manager)
- Chrome browser and ChromeDriver (for Selenium tests)
Using pip:
python3 -m venv .venv
source .venv/bin/activate
pip install -r requirements.txtOr using uv:
uv sync./scripts/restart_docker.shThis will start:
- PrestaShop shop at https://localhost:8443/pl
- Admin panel at https://localhost:8443/admin
- phpMyAdmin at http://localhost:8081
Admin credentials:
- Email:
admin@agrochowski.pl - Password:
StrongAdminPass123!
Run the interactive management CLI:
python config/manage.pyOr with uv:
python config/manage.py --use-uvThe CLI provides the following options:
- Run Scraper - Parse categories, products, and images from the reference website
- Run Initializer - Import scraped data into PrestaShop via API
- Reset Product Database - Truncate product tables (clean IDs)
- Enable Webservice - Configure PrestaShop API access (run this first!)
First-time setup:
- Wait for Docker containers to fully start
- Select option
4. Enable Webserviceto configure the API key - Then use other options as needed
python tests/test.pyNote: Ensure ChromeDriver is installed and matches your Chrome browser version.
- Yauheni Pyryeu
- Matsvei Kasparovich
- Valery Hulitsenka
- Yuriy Dyedyk
key-hard
| README.md
| .gitignore
| requirements.txt
| pyproject.toml
| pytest.ini
|
└───config # Docker & PrestaShop configuration
| | docker-compose.yml # Container orchestration
| | Dockerfile # PrestaShop image build
| | manage.py # Main CLI for managing the app
| └───certs # Self-signed SSL certificates
| └───scripts # Webservice enablement scripts
|
└───scripts # Utility scripts
| | restart_docker.sh # Start/restart Docker containers
|
└───themes # PrestaShop theme files
| └───agrochowski # Custom theme
|
└───scraper # Web scraper module
| └───src # Source code
| | └───initializer # PrestaShop API initializer
| | └───tests # Scraper tests
| └───results # Scraping output
| └───images # Downloaded images
|
└───tests # Selenium web testsEvery empty directory was initialized with .gitkeep file inside of it. It is needed to be deleted after any other content is created inside such directory.
If you only want to run the scraper without the full PrestaShop setup:
python scraper/src/parse.pyThis will parse categories, products, and images from the reference website and save them to scraper/results/.