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

chore: add derpserver to proxy, add proxies to derpmap#7311

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
deansheather merged 32 commits intomainfromdean/proxy-derp-map
Jul 26, 2023
Merged
Show file tree
Hide file tree
Changes from1 commit
Commits
Show all changes
32 commits
Select commitHold shift + click to select a range
eae4c3a
chore: add derpserver to proxy, add proxies to derpmap
deansheatherApr 27, 2023
ac99525
progress
deansheatherMay 1, 2023
4b68a0b
Merge branch 'main' into dean/proxy-derp-map
deansheatherMay 2, 2023
4ba7af6
progress
deansheatherMay 3, 2023
dcf072e
derp mesh probably working
deansheatherMay 4, 2023
2d2f1a3
deregister
deansheatherMay 4, 2023
28ae155
tests and various fixes
deansheatherMay 4, 2023
2baa362
Merge branch 'main' into dean/proxy-derp-map
deansheatherMay 4, 2023
5f5d4ff
more tests
deansheatherMay 5, 2023
5441dc8
merge main, remove proxy goingaway route
deansheatherMay 30, 2023
e4a3008
derp tests work
deansheatherMay 30, 2023
3caa692
Merge branch 'main' into dean/proxy-derp-map
deansheatherMay 30, 2023
404c3e4
update derp map on new connection
deansheatherMay 31, 2023
8544882
Merge branch 'main' into dean/proxy-derp-map
deansheatherJun 13, 2023
9b503fa
fixes
deansheatherJun 13, 2023
0e6d39a
tests for derp map changing
deansheatherJun 13, 2023
bb699fb
Merge branch 'main' into dean/proxy-derp-map
deansheatherJun 13, 2023
2943ac2
backwards compatible
deansheatherJun 20, 2023
f0fa578
other comments
deansheatherJun 20, 2023
9d90dc2
Merge branch 'main' into dean/proxy-derp-map
deansheatherJun 25, 2023
b405113
fixup! Merge branch 'main' into dean/proxy-derp-map
deansheatherJun 25, 2023
6a08a59
change derp map updates to be separate websocket
deansheatherJun 28, 2023
403eac5
Merge branch 'main' into dean/proxy-derp-map
deansheatherJul 17, 2023
d220266
Merge branch 'main' into dean/proxy-derp-map
deansheatherJul 24, 2023
9e658d6
fixup! Merge branch 'main' into dean/proxy-derp-map
deansheatherJul 24, 2023
67f2e5c
Working tests
deansheatherJul 25, 2023
3c96149
Merge branch 'main' into dean/proxy-derp-map
deansheatherJul 25, 2023
c26936a
fixup! Merge branch 'main' into dean/proxy-derp-map
deansheatherJul 25, 2023
e59de5a
fixup! Merge branch 'main' into dean/proxy-derp-map
deansheatherJul 25, 2023
2df067f
fixup! Merge branch 'main' into dean/proxy-derp-map
deansheatherJul 25, 2023
dfbfa96
Please
deansheatherJul 26, 2023
8223a35
fixup! Please
deansheatherJul 26, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
PrevPrevious commit
NextNext commit
progress
  • Loading branch information
@deansheather
deansheather committedMay 1, 2023
commitac995253b0139c5845b4aa7daf9b64b38e1fbe0b
10 changes: 10 additions & 0 deletionscoderd/apidoc/docs.go
View file
Open in desktop

Some generated files are not rendered by default. Learn more abouthow customized files appear on GitHub.

10 changes: 10 additions & 0 deletionscoderd/apidoc/swagger.json
View file
Open in desktop

Some generated files are not rendered by default. Learn more abouthow customized files appear on GitHub.

2 changes: 2 additions & 0 deletionscoderd/database/dbfake/databasefake.go
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -5206,6 +5206,7 @@ func (q *fakeQuerier) InsertWorkspaceProxy(_ context.Context, arg database.Inser
Name: arg.Name,
DisplayName: arg.DisplayName,
Icon: arg.Icon,
DerpEnabled: arg.DerpEnabled,
TokenHashedSecret: arg.TokenHashedSecret,
CreatedAt: arg.CreatedAt,
UpdatedAt: arg.UpdatedAt,
Expand All@@ -5223,6 +5224,7 @@ func (q *fakeQuerier) RegisterWorkspaceProxy(_ context.Context, arg database.Reg
if p.ID == arg.ID {
p.Url = arg.Url
p.WildcardHostname = arg.WildcardHostname
p.DerpEnabled = arg.DerpEnabled
p.UpdatedAt = database.Now()
q.workspaceProxies[i] = p
return p, nil
Expand Down
19 changes: 18 additions & 1 deletioncoderd/database/dump.sql
View file
Open in desktop

Some generated files are not rendered by default. Learn more abouthow customized files appear on GitHub.

View file
Open in desktop
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
ALTER TABLE workspace_proxies
DROP CONSTRAINT workspace_proxies_region_id_unique,
DROP COLUMN region_id,
DROP COLUMN derp_enabled;
View file
Open in desktop
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
ALTER TABLE workspace_proxies
-- adding a serial to a table without a default value will be filled as you
-- would expect
ADD COLUMN region_id serial NOT NULL,
ADD COLUMN derp_enabled boolean NOT NULL DEFAULT true,
ADD CONSTRAINT workspace_proxies_region_id_unique UNIQUE (region_id);
2 changes: 2 additions & 0 deletionscoderd/database/models.go
View file
Open in desktop

Some generated files are not rendered by default. Learn more abouthow customized files appear on GitHub.

42 changes: 32 additions & 10 deletionscoderd/database/queries.sql.go
View file
Open in desktop

Some generated files are not rendered by default. Learn more abouthow customized files appear on GitHub.

8 changes: 5 additions & 3 deletionscoderd/database/queries/proxies.sql
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -7,20 +7,22 @@ INSERT INTO
name,
display_name,
icon,
derp_enabled,
token_hashed_secret,
created_at,
updated_at,
deleted
)
VALUES
($1, '', '', $2, $3, $4, $5, $6, $7, false) RETURNING *;
($1, '', '', $2, $3, $4, $5, $6, $7,$8,false) RETURNING *;

-- name: RegisterWorkspaceProxy :one
UPDATE
workspace_proxies
SET
url = @url,
wildcard_hostname = @wildcard_hostname,
url = @url :: text,
wildcard_hostname = @wildcard_hostname :: text,
derp_enabled = @derp_enabled :: boolean,
updated_at = Now()
WHERE
id = @id
Expand Down
1 change: 1 addition & 0 deletionscoderd/database/unique_constraint.go
View file
Open in desktop

Some generated files are not rendered by default. Learn more abouthow customized files appear on GitHub.

8 changes: 7 additions & 1 deletioncodersdk/deployment.go
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -657,6 +657,7 @@ when required by your organization's security policy.`,
Value: &c.DERP.Server.Enable,
Group: &deploymentGroupNetworkingDERP,
YAML: "enable",
Annotations: clibase.Annotations{}.Mark(annotationExternalProxies, "true"),
},
{
Name: "DERP Server Region ID",
Expand All@@ -667,6 +668,7 @@ when required by your organization's security policy.`,
Value: &c.DERP.Server.RegionID,
Group: &deploymentGroupNetworkingDERP,
YAML: "regionID",
// Does not apply to external proxies as this value is generated.
},
{
Name: "DERP Server Region Code",
Expand All@@ -677,6 +679,7 @@ when required by your organization's security policy.`,
Value: &c.DERP.Server.RegionCode,
Group: &deploymentGroupNetworkingDERP,
YAML: "regionCode",
// Does not apply to external proxies as we use the proxy name.
},
{
Name: "DERP Server Region Name",
Expand All@@ -687,6 +690,7 @@ when required by your organization's security policy.`,
Value: &c.DERP.Server.RegionName,
Group: &deploymentGroupNetworkingDERP,
YAML: "regionName",
// Does not apply to external proxies as we use the proxy name.
},
{
Name: "DERP Server STUN Addresses",
Expand All@@ -703,10 +707,12 @@ when required by your organization's security policy.`,
Description: "An HTTP URL that is accessible by other replicas to relay DERP traffic. Required for high availability.",
Flag: "derp-server-relay-url",
Env: "CODER_DERP_SERVER_RELAY_URL",
Annotations: clibase.Annotations{}.Mark(annotationEnterpriseKey, "true"),
Value: &c.DERP.Server.RelayURL,
Group: &deploymentGroupNetworkingDERP,
YAML: "relayURL",
Annotations: clibase.Annotations{}.
Mark(annotationEnterpriseKey, "true").
Mark(annotationExternalProxies, "true"),
},
{
Name: "DERP Config URL",
Expand Down
8 changes: 5 additions & 3 deletionscodersdk/workspaceproxy.go
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -46,13 +46,15 @@ type ProxyHealthReport struct {
}

type WorkspaceProxy struct {
ID uuid.UUID `json:"id" format:"uuid" table:"id"`
Name string `json:"name" table:"name,default_sort"`
Icon string `json:"icon" table:"icon"`
ID uuid.UUID `json:"id" format:"uuid" table:"id"`
Name string `json:"name" table:"name,default_sort"`
DisplayName string `json:"display_name" table:"display_name"`
Icon string `json:"icon" table:"icon"`
// Full url including scheme of the proxy api url: https://us.example.com
URL string `json:"url" table:"url"`
// WildcardHostname with the wildcard for subdomain based app hosting: *.us.example.com
WildcardHostname string `json:"wildcard_hostname" table:"wildcard_hostname"`
DerpEnabled bool `json:"derp_enabled" table:"derp_enabled"`
CreatedAt time.Time `json:"created_at" format:"date-time" table:"created_at"`
UpdatedAt time.Time `json:"updated_at" format:"date-time" table:"updated_at"`
Deleted bool `json:"deleted" table:"deleted"`
Expand Down
Loading

[8]ページ先頭

©2009-2025 Movatter.jp