The calculator app build using the React, Lumen, Photon, Docker
Make sure you have installed the docker and docker-compose before using this application you can find the guide here
*clone the project from git
git clone https://github.com/moeen-basra/react-calculator
-
go to api folder and create env file, copy content from .env.example and update
-
got app edit .env and update the ip for app
-
go to project root directory and run the command
docker-compose -f docker-compose.prod.yml build
- run the containers
docker-compose -f docker-compose.prod.yml up -d
- open your favorite brower and paste the follwoing url
http://{hostip}:8087
- for api use the following url
http://{hostip}:8088
# API to calcualte
POST: http://{hostip}:8088/calculate
params: {
operand1: required,
operand2: required,
operator: required // +,-,/,*,%,√,3√,xy,x!
}
# API for reports
# note: please use the encodeURI for operators
GET: http://moeen.me:8088/reports
params: {
interval: required // daily, weekly, monthly
operator: required // +,-,/,*,%,√,3√,xy,x!
page: optional
}
- for jenkins
http://{hostip}:8089
- reterive the jenkins key from logs and paste. Next continue with recommended plugins and ccreate a user. Verify your url thats it.
you are ready to create pipe lines for build and deployments.
Please check the demo
There is alot of space for the imporvements