Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit c3ba85a

Browse files
chore: fix issues
1 parent a2ee1a6 commit c3ba85a

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

agent/agentcontainers/api.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1191,6 +1191,7 @@ func (api *API) maybeInjectSubAgentIntoContainerLocked(ctx context.Context, dc c
11911191
OperatingSystem: "linux", // Assuming Linux for devcontainers.
11921192
Architecture: arch,
11931193
DisplayApps: displayApps,
1194+
Apps: apps,
11941195
})
11951196
if err != nil {
11961197
return xerrors.Errorf("create subagent failed: %w", err)

agent/agentcontainers/subagent.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ func (a *subAgentAPIClient) Create(ctx context.Context, agent SubAgent) (SubAgen
150150
}
151151
}
152152

153-
var share *agentproto.CreateSubAgentRequest_App_Share
153+
var share *agentproto.CreateSubAgentRequest_App_SharingLevel
154154
if app.Share != nil {
155155
switch *app.Share {
156156
case codersdk.WorkspaceAppSharingLevelAuthenticated:
@@ -159,6 +159,8 @@ func (a *subAgentAPIClient) Create(ctx context.Context, agent SubAgent) (SubAgen
159159
share = agentproto.CreateSubAgentRequest_App_OWNER.Enum()
160160
case codersdk.WorkspaceAppSharingLevelPublic:
161161
share = agentproto.CreateSubAgentRequest_App_PUBLIC.Enum()
162+
case codersdk.WorkspaceAppSharingLevelOrganization:
163+
share = agentproto.CreateSubAgentRequest_App_ORGANIZATION.Enum()
162164
default:
163165
return SubAgent{}, xerrors.Errorf("unexpected codersdk.WorkspaceAppSharingLevel: %#v", app.Share)
164166
}

0 commit comments

Comments
 (0)