Ecommerce backend apis
- This is a Maven Project. Ensure, Maven is installed on your system.
- It is Recommended that you use Linux Based OS.
- It might happen that you have installed XAMPP/LAMPP software (by Bitnami) on your system. Instead of using the db provided by XAMPP/LAMPP by bitnami, it is recommended that you install
mariadb-serverand use it as database while running this application.
###How to run in local
- Change the Application Properties (E.g. username/password of DB) present in
resources/application.propertiesaccording to your local mysql-server. - Create a database called
ecommercewithCHARACTER SET utf8mb4andCOLLATE utf8mb4_0900_ai_ci. MariaDB does not supportCOLLATE utf8mb4_0900_ai_ci. So, if you are using MariaDB, opendatabase-dump.sqlfile and replaceCOLLATE utf8mb4_0900_ai_ciwithCOLLATE utf8mb4_general_ci - Import
database-dump.sqlin it. - To run the application, run the command
sh run.shi.e. execute therun.shfile. - After starting application, go to http://localhost:8080/api/swagger-ui.html/
- The input for updating the category via API is
{
"categoryName":"name",
"imageUrl":"url",
"description":"desc"
}
- Go into pom.xml and comment out the scope for the "spring-boot-starter-tomcat" dependency
mvn package java -jar -Dspring.profiles.active=prod
- ssh root@167.99.37.15
- (use password: webTuts9plus)
- cd ecommerce
- git pull
- sh run.sh
- you should see the swagger UI in http://167.99.37.15:8080/api/swagger-ui.html
#admin access email: admin@gmail.com password: admin firstname: admin
##export database mysqldump -u root -p ecommerce > database-dump.sql scp root@104.236.26.66:database-dump.sql .