Skip to content

Commit

Permalink
[installer] Add enforce flag
Browse files Browse the repository at this point in the history
  • Loading branch information
Furisto authored and roboquat committed Oct 18, 2022
1 parent 9e39e66 commit 0a38956
Show file tree
Hide file tree
Showing 13 changed files with 25 additions and 11 deletions.

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

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

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

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

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

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

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

3 changes: 2 additions & 1 deletion install/installer/cmd/testdata/render/minimal/output.golden

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

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

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

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

2 changes: 2 additions & 0 deletions install/installer/pkg/components/ws-daemon/configmap.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ func configmap(ctx *common.RenderContext) ([]runtime.Object, error) {
var procLimit int64
networkLimitConfig := netlimit.Config{
Enabled: false,
Enforce: false,
ConnectionsPerMinute: 3000,
BucketSize: 1000,
}
Expand All @@ -74,6 +75,7 @@ func configmap(ctx *common.RenderContext) ([]runtime.Object, error) {
ioLimitConfig.ReadIOPS = ucfg.Workspace.IOLimits.ReadIOPS

networkLimitConfig.Enabled = ucfg.Workspace.NetworkLimits.Enabled
networkLimitConfig.Enforce = ucfg.Workspace.NetworkLimits.Enforce
networkLimitConfig.ConnectionsPerMinute = ucfg.Workspace.NetworkLimits.ConnectionsPerMinute
networkLimitConfig.BucketSize = ucfg.Workspace.NetworkLimits.BucketSize

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ type WorkspaceConfig struct {
} `json:"ioLimits"`
NetworkLimits struct {
Enabled bool `json:"enabled"`
Enforce bool `json:"enforce"`
ConnectionsPerMinute int64 `json:"connectionsPerMinute"`
BucketSize int64 `json:"bucketSize"`
} `json:"networkLimits"`
Expand Down

0 comments on commit 0a38956

Please sign in to comment.