Skip to content

Commit

Permalink
Remove comments
Browse files Browse the repository at this point in the history
  • Loading branch information
damien-duignan committed Jun 9, 2020
1 parent 3cf9b80 commit 4d24a5c
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 8 deletions.
8 changes: 0 additions & 8 deletions db/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,8 @@ const { Pool } = require("pg");

const pool = new Pool({
connectionString: `${process.env.CONNECTION_STRING}`
// user: process.env.DATABASE_USER,
// host: process.env.DATABASE_HOST,
// database: process.env.DATABASE_NAME,
// password: process.env.DATABASE_PASSWORD,
// port: process.env.DATABASE_PORT,
});


// console.log('pool: ', pool.);

module.exports = {
query: (text, params) => pool
.query(text, params)
Expand Down
25 changes: 25 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,28 @@ services:

ports:
- "8080:8080"

depends_on:
- productdb

environment:
CONNECTION_STRING: postgresql://product_robot:pr0dr0b0t@productdb:5432/product

productdb:
image: postgres:11

volumes:
# Volume for startup scripts. Note this willonly run if there is nothing in /var/lib/postgresql/data
- ./devdatabase/db-init-scripts:/docker-entrypoint-initdb.d

# Volume for persistance between runs. Uncomment if you wish to retain data.
# - ./devdatabase/volume:/var/lib/postgresql/data

expose:
- "5432"

ports:
- "5432:5432"

environment:
POSTGRES_PASSWORD: pgsqlDev01

0 comments on commit 4d24a5c

Please sign in to comment.