File tree Expand file tree Collapse file tree 2 files changed +44
-1
lines changed
Expand file tree Collapse file tree 2 files changed +44
-1
lines changed Original file line number Diff line number Diff line change 1+ # Postgres Docker Container
2+
3+ This is a containerized Postgres database
4+
5+ <!-- INSTALLATION -->
6+
7+ ### Installation
8+
9+ 1 . Clone the repo
10+
11+ ``` sh
12+ git clone https://github.com/wardvisual/dockerized-db.git
13+ ```
14+
15+ <!-- Setup -->
16+
17+ ### Setup
18+
19+ 1 . To run the container, use the following command:
20+
21+ ``` sh
22+ sudo docker compose up
23+ ```
24+
25+ 2 . To open a bash shell in the container, use the following command:
26+
27+ ``` sh
28+ sudo docker exec -it [container_name] bash
29+ ```
30+
31+ 3 . To login as posgress local account, use the following command:
32+
33+ ``` sh
34+ psql -h localhost -p 5432 -U postgres
35+ ```
36+
37+ <hr />
38+
39+ I hope this helps! Let me know if you have any other questions.
40+
41+ ### Contact
42+
43+ Edward Fernandez: [ Wardvisual] ( https://wardvisual.me/ )
Original file line number Diff line number Diff line change @@ -7,7 +7,7 @@ services:
77 ports :
88 - 5432:5432
99 environment :
10- - POSTGRES_USER=__user__
10+ - POSTGRES_USER=postgres
1111 - POSTGRES_PASSWORD=__pass__
1212 volumes :
1313 - $HOME/core/docker/database/postgres/data:/var/lib/postgres
You can’t perform that action at this time.
0 commit comments