Docker must be installed to run the project.
Docker Services
- Nginx for Web server local.currency-converter.com
- Php 8.0-fpm
- Mysql 8.0 for Database
- Composer to install dependecies
- Phinx For Database Migration
For mac user sudo nano /etc/hosts to add custom local environment domain 127.0.0.1 local.currency-converter.com
docker-compose up to start the local environment services
App Running To convert currency request converter.php endpoint with required parameters; action, sourceCurrency, targetCurrency and sourceAmount parameter
To run test with Docker below command to check target amount test
docker exec php-container /var/www/html/currency-converter/vendor/bin/phpunit /var/www/html/currency-converter/tests/ConverterTest.php