Skip to content

Express/React/Redux/PostgreSQL Dockerized Fullstack application starter.

Notifications You must be signed in to change notification settings

melhotiby/react-redux-express-postgresql

Repository files navigation

Express/React/Redux/PostgreSQL Dockerized Fullstack application starter.

This repository contains a production ready template which includes the following


Development

For initial setup you will need to:

Copy the server .env.example to .env

cp -n server/.env{.example,}

Copy the server docker-compose.override.example.yml to docker-compose.override.yml for docker compose overrides

cp -n docker-compose.override{.example,}.yml

Start all the services with docker

docker-compose up --build

Create the new database table

docker-compose run --rm api yarn db:create

Migrate the database

docker-compose run --rm api yarn db:migrate

Seed the database

docker-compose run --rm api yarn db:seed

Running tests

docker-compose run --rm client yarn test

SSH into elastic beanstalk and run commands

ssh -i docker.pem ec2-user@<PUBLIC_IP_ADDRESS>
sudo su
docker ps
docker exec -it <DOCKER_INSTANCE_FOR_elhotiby1/multi-server> docker-entrypoint.sh sh
yarn db:migrate
yarn db:seed

Visit localhost:3000