Giter VIP home page Giter VIP logo

bkrm-api's Introduction

BKRM API - Bach Khoa Retail Management System API

  • Updated at : 22 Oct 2022 by Hai Ly.

A. INTRODUCTION This is backend implementation of our project for graduation thesis: BUILD A RETAIL MANAGEMENT SYSTEM SUPPORTING AUTOMATION. 30 June 2022 - Ho Chi Minh University of Technology Supervisor:

  • Assoc. Professor Tran Minh Quang Members:
  • Ly Quoc Hai (Backend)
  • Dang Gia Le (Frontend)
  • Mai Truong Khang (Frontend)

B. HOW TO RUN THIS CODE

  1. Requirements
  1. Steps to run this code for the first time. For automatically setup for window you can run setup.bat file. For set up manually:
  • In root folder Create a copy of .env.sample and named it .env
  • Download merge.zip and extract it to a folder merged in the root folder
  • Build the app image with the following command
  • docker-compose may be docker compose (if use docker utils) docker compose build app
  • Run the environment in background mode docker compose up -d
  • (Optional) Show information about the state of your active service docker compose ps
  • Run composer install to install the application dependencies. docker compose exec app rm -rf vendor composer.lock docker compose exec app composer install
  • Generate a unique application key with the artisan Laravel command-line tool. docker compose exec app php artisan key:generate
  • Link storage to update images docker compose exec app php artisan storage:link Finally you now can access BKRM backend through:
  • http://server_domain_or_IP:8000/api
  • http://localhost:8000/api
  1. Code changes are automatically sync with the deploy code in the container

  2. Restart when updating docker-compose.yml or Dockerfile docker-compose up -d

  3. Database persistence folder:

  • Database on a run session is store in folder bkrm_persistent_data.
  • If you delete this folder, the database will be refreshed back to the init_db.sql in docker_composer/mariadb

OTHER USEFUL DOCKER COMMANDS:

  • Command to check the logs generated by docker services. ie: nginx docker-compose logs nginx
  • Pause your Docker Compose environment while keeping the state of all its services, run: docker-compose pause
  • Resume your services with: docker-compose unpause
  • Shut down your Docker Compose environment and remove all of its containers, networks, and volumes, run: docker-compose down
  • Execute commands in a docker container: docker-compose exec {service name} {command} Ex: docker-compose exec app composer install: Run composer install inside app container

For an overview of all Docker Compose commands, please check the Docker Compose command-line reference: https://docs.docker.com/compose/reference/

C. CODE STRUCTURE: An general explaination of the meaning of main folder and files. For detail, please read Laravel Docs

bkrm-api's People

Contributors

haily835 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.