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

Commit2ebda31

Browse files
committed
Merge remote-tracking branch 'origin/main' into ssncferreira/tests-reconcile-prebuilds-expiration
2 parentsb385ce6 +af4a668 commit2ebda31

File tree

63 files changed

+3558
-1356
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

63 files changed

+3558
-1356
lines changed

‎.editorconfig

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@ indent_style = tab
1111
indent_style =space
1212
indent_size =2
1313

14+
[*.proto]
15+
indent_style =space
16+
indent_size =2
17+
1418
[coderd/database/dump.sql]
1519
indent_style =space
1620
indent_size =4

‎.github/workflows/ci.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@ jobs:
187187
188188
# Check for any typos
189189
-name:Check for typos
190-
uses:crate-ci/typos@0f0ccba9ed1df83948f0c15026e4f5ccfce46109# v1.32.0
190+
uses:crate-ci/typos@b1ae8d918b6e85bd611117d3d9a3be4f903ee5e4# v1.33.1
191191
with:
192192
config:.github/workflows/typos.toml
193193

@@ -902,7 +902,7 @@ jobs:
902902
# the check to pass. This is desired in PRs, but not in mainline.
903903
-name:Publish to Chromatic (non-mainline)
904904
if:github.ref != 'refs/heads/main' && github.repository_owner == 'coder'
905-
uses:chromaui/action@d7afd50124cf4f337bcd943e7f45cfa85a5e4476# v12.0.0
905+
uses:chromaui/action@8536229ee904071f8edce292596f6dbe0da96b9b# v12.1.1
906906
env:
907907
NODE_OPTIONS:"--max_old_space_size=4096"
908908
STORYBOOK:true
@@ -934,7 +934,7 @@ jobs:
934934
# infinitely "in progress" in mainline unless we re-review each build.
935935
-name:Publish to Chromatic (mainline)
936936
if:github.ref == 'refs/heads/main' && github.repository_owner == 'coder'
937-
uses:chromaui/action@d7afd50124cf4f337bcd943e7f45cfa85a5e4476# v12.0.0
937+
uses:chromaui/action@8536229ee904071f8edce292596f6dbe0da96b9b# v12.1.1
938938
env:
939939
NODE_OPTIONS:"--max_old_space_size=4096"
940940
STORYBOOK:true

‎.github/workflows/scorecard.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,6 @@ jobs:
4747

4848
# Upload the results to GitHub's code scanning dashboard.
4949
-name:"Upload to code-scanning"
50-
uses:github/codeql-action/upload-sarif@ff0a06e83cb2de871e5a09832bc6a81e7276941f# v3.28.18
50+
uses:github/codeql-action/upload-sarif@fca7ace96b7d713c7035871441bd52efbe39e27e# v3.28.19
5151
with:
5252
sarif_file:results.sarif

‎.github/workflows/security.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ jobs:
3838
uses:./.github/actions/setup-go
3939

4040
-name:Initialize CodeQL
41-
uses:github/codeql-action/init@ff0a06e83cb2de871e5a09832bc6a81e7276941f# v3.28.18
41+
uses:github/codeql-action/init@fca7ace96b7d713c7035871441bd52efbe39e27e# v3.28.19
4242
with:
4343
languages:go, javascript
4444

@@ -48,7 +48,7 @@ jobs:
4848
rm Makefile
4949
5050
-name:Perform CodeQL Analysis
51-
uses:github/codeql-action/analyze@ff0a06e83cb2de871e5a09832bc6a81e7276941f# v3.28.18
51+
uses:github/codeql-action/analyze@fca7ace96b7d713c7035871441bd52efbe39e27e# v3.28.19
5252

5353
-name:Send Slack notification on failure
5454
if:${{ failure() }}
@@ -142,15 +142,15 @@ jobs:
142142
echo "image=$(cat "$image_job")" >> $GITHUB_OUTPUT
143143
144144
-name:Run Trivy vulnerability scanner
145-
uses:aquasecurity/trivy-action@6c175e9c4083a92bbca2f9724c8a5e33bc2d97a5
145+
uses:aquasecurity/trivy-action@76071ef0d7ec797419534a183b498b4d6366cf37
146146
with:
147147
image-ref:${{ steps.build.outputs.image }}
148148
format:sarif
149149
output:trivy-results.sarif
150150
severity:"CRITICAL,HIGH"
151151

152152
-name:Upload Trivy scan results to GitHub Security tab
153-
uses:github/codeql-action/upload-sarif@ff0a06e83cb2de871e5a09832bc6a81e7276941f# v3.28.18
153+
uses:github/codeql-action/upload-sarif@fca7ace96b7d713c7035871441bd52efbe39e27e# v3.28.19
154154
with:
155155
sarif_file:trivy-results.sarif
156156
category:"Trivy"

‎agent/agent.go

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1080,6 +1080,18 @@ func (a *agent) handleManifest(manifestOK *checkpoint) func(ctx context.Context,
10801080
ifmanifest.AgentID==uuid.Nil {
10811081
returnxerrors.New("nil agentID returned by manifest")
10821082
}
1083+
ifmanifest.ParentID!=uuid.Nil {
1084+
// This is a sub agent, disable all the features that should not
1085+
// be used by sub agents.
1086+
a.logger.Debug(ctx,"sub agent detected, disabling features",
1087+
slog.F("parent_id",manifest.ParentID),
1088+
slog.F("agent_id",manifest.AgentID),
1089+
)
1090+
ifa.experimentalDevcontainersEnabled {
1091+
a.logger.Info(ctx,"devcontainers are not supported on sub agents, disabling feature")
1092+
a.experimentalDevcontainersEnabled=false
1093+
}
1094+
}
10831095
a.client.RewriteDERPMap(manifest.DERPMap)
10841096

10851097
// Expand the directory and send it back to coderd so external
@@ -1188,7 +1200,7 @@ func (a *agent) handleManifest(manifestOK *checkpoint) func(ctx context.Context,
11881200
// createOrUpdateNetwork waits for the manifest to be set using manifestOK, then creates or updates
11891201
// the tailnet using the information in the manifest
11901202
func (a*agent)createOrUpdateNetwork(manifestOK,networkOK*checkpoint)func(context.Context, proto.DRPCAgentClient26)error {
1191-
returnfunc(ctx context.Context,_ proto.DRPCAgentClient26) (retErrerror) {
1203+
returnfunc(ctx context.Context,aAPI proto.DRPCAgentClient26) (retErrerror) {
11921204
iferr:=manifestOK.wait(ctx);err!=nil {
11931205
returnxerrors.Errorf("no manifest: %w",err)
11941206
}
@@ -1208,6 +1220,7 @@ func (a *agent) createOrUpdateNetwork(manifestOK, networkOK *checkpoint) func(co
12081220
// agent API.
12091221
network,err=a.createTailnet(
12101222
a.gracefulCtx,
1223+
aAPI,
12111224
manifest.AgentID,
12121225
manifest.DERPMap,
12131226
manifest.DERPForceWebSockets,
@@ -1355,6 +1368,7 @@ func (a *agent) trackGoroutine(fn func()) error {
13551368

13561369
func (a*agent)createTailnet(
13571370
ctx context.Context,
1371+
aAPI proto.DRPCAgentClient26,
13581372
agentID uuid.UUID,
13591373
derpMap*tailcfg.DERPMap,
13601374
derpForceWebSockets,disableDirectConnectionsbool,
@@ -1487,7 +1501,7 @@ func (a *agent) createTailnet(
14871501
}()
14881502
iferr=a.trackGoroutine(func() {
14891503
deferapiListener.Close()
1490-
apiHandler,closeAPIHAndler:=a.apiHandler()
1504+
apiHandler,closeAPIHAndler:=a.apiHandler(aAPI)
14911505
deferfunc() {
14921506
_=closeAPIHAndler()
14931507
}()

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp