File tree Expand file tree Collapse file tree 2 files changed +11
-7
lines changed Expand file tree Collapse file tree 2 files changed +11
-7
lines changed Original file line number Diff line number Diff line change 4
4
"name" : " PostgreSQL and PG Admin" ,
5
5
"waitFor" : " onCreateCommand" ,
6
6
"dockerComposeFile" : " docker-compose.yml" ,
7
- "service" : " db " ,
7
+ "service" : " postgresql " ,
8
8
"workspaceFolder" : " /workspaces/${localWorkspaceFolderBasename}" ,
9
9
// Features to add to the dev container. More info: https://containers.dev/features.
10
10
// "features": {},
31
31
}
32
32
},
33
33
"forwardPorts" : [
34
- 5432 ,
34
+ // 5432,
35
35
8080
36
36
],
37
37
// Use 'postCreateCommand' to run commands after the container is created.
38
- // "postCreateCommand": "yarn install ",
38
+ "postCreateCommand" : " ls -al " ,
39
39
// Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
40
40
// "remoteUser": "vscode"
41
41
}
Original file line number Diff line number Diff line change 1
1
version : ' 3.8'
2
2
3
3
services :
4
- db :
4
+ postgresql :
5
5
image : postgres:latest
6
6
restart : unless-stopped
7
7
volumes :
@@ -10,17 +10,21 @@ services:
10
10
POSTGRES_USER : postgres
11
11
POSTGRES_DB : postgres
12
12
POSTGRES_PASSWORD : postgres
13
+ network_mode : service:pgadmin
14
+
15
+ # ports:
16
+ # - "5432:5432"
13
17
# Add "forwardPorts": ["5432"] to **devcontainer.json** to forward PostgreSQL locally.
14
18
# (Adding the "ports" property to this file will not forward from a Codespace.)
15
19
16
20
pgadmin :
17
- image : dpage/pgadmin4:6.10
21
+ image : dpage/pgadmin4:8.3
18
22
restart : unless-stopped
19
23
volumes :
20
24
- pgadmin-data:/var/lib/pgadmin
21
25
environment :
22
- PGADMIN_DEFAULT_EMAIL : jonhdoe@gmail .com
23
- PGADMIN_DEFAULT_PASSWORD : StrongPassword
26
+ PGADMIN_DEFAULT_EMAIL : sql@mongodb .com
27
+ PGADMIN_DEFAULT_PASSWORD : password
24
28
PGADMIN_LISTEN_PORT : 8080
25
29
PGADMIN_CONFIG_PROXY_X_HOST_COUNT : 1
26
30
PGADMIN_CONFIG_PROXY_X_PREFIX_COUNT : 1
You can’t perform that action at this time.
0 commit comments