Update README.md

Signed-off-by: Utkarsh Mathur <78642104+MathurUtkarsh@users.noreply.github.com>
Signed-off-by: Utkarsh Mathur <utkarshmathur05@gmail.com>
pull/321/head
Utkarsh Mathur 1 year ago committed by Utkarsh Mathur
parent 007c776a86
commit c62ffcdc52
  1. 8
      nodejs-postgres/README.md

@ -1,4 +1,4 @@
##NodeJS with Postgres Connection
# NodeJS with Postgres Connection
This is a sample project that demonstrates how to connect a NodeJS app using Express to a Postgres database using Docker Compose. The project includes the following components:
@ -6,14 +6,14 @@ This is a sample project that demonstrates how to connect a NodeJS app using Exp
2. Postgres database
3. Docker Compose file to set up the environment
##Project Structure
## Project Structure
The project consists of the following files:
1. _docker-compose.yml_: The Docker Compose file that defines the services for the NodeJS app and Postgres database, and the network connections between them.
2. _nodejs directory_: Contains the NodeJS code, including index.js and Dockerfile for building the NodeJS app image.
3. _postgres directory_: Contains the Dockerfile for building the Postgres database image.
##Getting Started
## Getting Started
To run this project, follow these steps:
1. Clone the repository.
@ -22,5 +22,5 @@ To run this project, follow these steps:
Expected Results
When you access the NodeJS app at http://localhost:3000, you should see the message "Hello World!" displayed in the browser.
##Conclusion
## Conclusion
This project provides a simple example of how to connect a NodeJS app to a Postgres database using Docker Compose. The project structure follows a standard naming convention and separates the code for the two services into separate directories. By using Docker Compose, it's easy to set up a development environment that can be used to test and debug your NodeJS and Postgres applications.

Loading…
Cancel
Save