Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 4 additions & 0 deletions app/src/types/generated/lit-autopilot_pb.d.ts

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

29 changes: 28 additions & 1 deletion app/src/types/generated/lit-autopilot_pb.js

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

3 changes: 3 additions & 0 deletions app/src/types/generated/lit-sessions_pb.d.ts

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

31 changes: 30 additions & 1 deletion app/src/types/generated/lit-sessions_pb.js

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

2 changes: 2 additions & 0 deletions app/src/util/tests/sampleData.ts
Original file line number Diff line number Diff line change
Expand Up @@ -972,6 +972,7 @@ export const litListSessions: LIT.ListSessionsResponse.AsObject = {
},
],
],
featureConfigsMap: [['SampleFeature', '{}']],
},
{
id: '',
Expand Down Expand Up @@ -1053,6 +1054,7 @@ export const litListSessions: LIT.ListSessionsResponse.AsObject = {
},
],
],
featureConfigsMap: [['SampleFeature', '{}']],
},
],
};
Expand Down
9 changes: 5 additions & 4 deletions autopilotserver/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -357,10 +357,11 @@ func (c *Client) ListFeatures(ctx context.Context) (map[string]*Feature,
perms := unmarshalPermissions(feature.PermissionsList)
rules := unmarshalRules(feature.Rules)
features[i] = &Feature{
Name: feature.Name,
Description: feature.Description,
Permissions: perms,
Rules: rules,
Name: feature.Name,
Description: feature.Description,
Permissions: perms,
Rules: rules,
DefaultConfig: feature.DefaultConfig,
}
}

Expand Down
5 changes: 5 additions & 0 deletions autopilotserver/interface.go
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,11 @@ type Feature struct {
// Rules is a list of all the firewall that must be specified for this
// feature.
Rules map[string]*RuleValues

// DefaultConfig is a JSON-serialized configuration of the feature. It
// represents the default configuration we can use if the user doesn't
// specify any.
DefaultConfig []byte
}

// RuleValues holds the default value along with the sane max and min values
Expand Down
Loading