Skip to content

Commit 14f5e58

Browse files
committed
chore(devcontainer): forward services ports
Signed-off-by: Vladislav Polyakov <[email protected]>
1 parent 8370f60 commit 14f5e58

File tree

4 files changed

+22
-21
lines changed

4 files changed

+22
-21
lines changed

.devcontainer/cluster/compose.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,8 +56,8 @@ services:
5656
- deployment=docker
5757

5858
ports:
59-
- 2136:2136
60-
- 8765:8765
59+
- 2136
60+
- 8765
6161

6262
volumes:
6363
- ydb-data:/ydb_data
@@ -134,7 +134,7 @@ services:
134134
platform: linux/amd64
135135

136136
ports:
137-
- 9090:9090
137+
- 9090
138138

139139
volumes:
140140
- ../prometheus.yml:/etc/prometheus/prometheus.yml

.devcontainer/cluster/devcontainer.json

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,13 @@
66
"dockerComposeFile": "compose.yml",
77
"workspaceFolder": "/workspaces/ydb-js-sdk",
88
// Allows the container to use ptrace, which is useful for debugging.
9-
"capAdd": ["SYS_PTRACE"],
9+
"capAdd": [
10+
"SYS_PTRACE"
11+
],
1012
// Disables seccomp, which can be necessary for some debugging tools to function correctly.
11-
"securityOpt": ["seccomp=unconfined"],
13+
"securityOpt": [
14+
"seccomp=unconfined"
15+
],
1216
// Features to add to the dev container. More info: https://containers.dev/features.
1317
"features": {
1418
"ghcr.io/devcontainers/features/git": {},
@@ -17,11 +21,9 @@
1721
},
1822
// Use 'forwardPorts' to make a list of ports inside the container available locally.
1923
"forwardPorts": [
20-
2136,
21-
8765,
22-
19001,
23-
9090,
24-
9464
24+
"ydb-storage:2136",
25+
"ydb-storage:8765",
26+
"prometheus:9090"
2527
],
2628
// Use 'initializeCommand' to run commands before the container is created.
2729
"initializeCommand": "chmod +x .devcontainer/commands/initialize.sh && .devcontainer/commands/initialize.sh",

.devcontainer/compose.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ services:
1919
- ../:/workspaces/ydb-js-sdk:cached
2020

2121
environment:
22-
- YDB_VERSION=25.1.1.3
22+
- YDB_VERSION=25.1
2323
- YDB_STATIC_CREDENTIALS_USER=root
2424
- YDB_STATIC_CREDENTIALS_PASSWORD=1234
2525
- YDB_STATIC_CREDENTIALS_ENDPOINT=grpc://ydb:2136
@@ -31,15 +31,15 @@ services:
3131
command: sleep infinity
3232

3333
ydb:
34-
image: ghcr.io/ydb-platform/local-ydb:25.1.1.3
34+
image: ydb-platform/local-ydb:25.1
3535
restart: unless-stopped
3636
hostname: ydb
3737
platform: linux/amd64
3838

3939
ports:
40-
- 2135:2135
41-
- 2136:2136
42-
- 8765:8765
40+
- 2135
41+
- 2136
42+
- 8765
4343

4444
volumes:
4545
- ydb-data:/ydb_data
@@ -58,7 +58,7 @@ services:
5858
platform: linux/amd64
5959

6060
ports:
61-
- 9090:9090
61+
- 9090
6262

6363
volumes:
6464
- ydb-certs:/ydb_certs

.devcontainer/devcontainer.json

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,10 @@
2121
},
2222
// Use 'forwardPorts' to make a list of ports inside the container available locally.
2323
"forwardPorts": [
24-
2135,
25-
2136,
26-
8765,
27-
9090,
28-
9464
24+
"ydb:2135",
25+
"ydb:2136",
26+
"ydb:8765",
27+
"prometheus:9090"
2928
],
3029
// Use 'initializeCommand' to run commands before the container is created.
3130
"initializeCommand": "chmod +x .devcontainer/commands/initialize.sh && .devcontainer/commands/initialize.sh",

0 commit comments

Comments
 (0)