Skip to content

christiancrisologo/fullstack-react-express-mysql-docker

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

FULL STACK LOGIN USER APP

  • A fullstack application ready to deploy to CI/CD with docker + database, ReactJS UI client + ExpressJS server + unit test .

Prerequisite

Setup and run Docker

  • Create default docker machine with $ docker-machine create default
  • Run the default docker-machine $ docker-machine start default
  • Fix for old osx to set the docker-machine default ip, '$ eval "$(docker-machine env default)'
  • Once the docker-machine default running, run the docker-compose and deploy $ docker-compose up -d

Running the App in local thru Docker

  • Bind the ip to local client using
  `$ curl $(docker-machine ip default):3000`
  • Do the same for the server
  `$ curl $(docker-machine ip default):4000`
  • Check the ip being used and use it as your localhost
  `$ docker-machine ip`
  • To run the MySQL in local, you can use your IDE SQL using the docker yml config. In case theres a local connection issue, try to use the docker msql container sql shell
  `$ docker exec -it mysql1 mysql -u root -p`

Running in dev local

  • To test dev frontend in local, go to client directory then install and run the app
  `$ npm i && npm start`
  • To test dev backend in local, go to server directory then install and run the app. (NOTE! If the DB is not accessable in your local then its better to run it in docker)
  `$ npm i && npm start`

About

Simple Login app using React + Express + MySQL + Docker + unit testing

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published