Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commite699ba1

Browse files
committed
fix: example: update docker-local to use host-gateway
1 parent55bd7aa commite699ba1

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

‎docker-compose.yaml‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,9 @@ services:
77
environment:
88
CODER_PG_CONNECTION_URL:"postgresql://username:password@database/coder?sslmode=disable"
99
CODER_ADDRESS:"0.0.0.0:7080"
10+
CODER_ACCESS_URL:"http://host.docker.internal:7080"
11+
volumes:
12+
-/var/run/docker.sock:/var/run/docker.sock
1013
depends_on:
1114
database:
1215
condition:service_healthy

‎examples/docker-local/main.tf‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,10 @@ resource "docker_container" "workspace" {
4343
dns=["1.1.1.1"]
4444
command=["sh","-c",coder_agent.dev.init_script]
4545
env=["CODER_AGENT_TOKEN=${coder_agent.dev.token}"]
46+
host {
47+
host="host.docker.internal"
48+
ip="host-gateway"
49+
}
4650
volumes {
4751
container_path="/home/coder/"
4852
volume_name=docker_volume.coder_volume.name

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp