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
2 changes: 1 addition & 1 deletion cmd/generate-config/config/config-openapi-spec.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
"maxFileAge": {
"description": "maxFileAge is the maximum number of days to retain old audit log files",
"type": "integer",
"default": 10
"default": 0
},
"maxFileSize": {
"description": "maxFileSize is the maximum size in megabytes of the audit log file before it gets rotated",
Expand Down
2 changes: 1 addition & 1 deletion docs/user/howto_config.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ In case `config.yaml` is not provided, the following default settings will be us
apiServer:
advertiseAddress: ""
auditLog:
maxFileAge: 10
maxFileAge: 0
maxFileSize: 200
maxFiles: 10
profile: Default
Expand Down
2 changes: 1 addition & 1 deletion packaging/microshift/config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apiServer:
advertiseAddress: ""
auditLog:
# maxFileAge is the maximum number of days to retain old audit log files
maxFileAge: 10
maxFileAge: 0
# maxFileSize is the maximum size in megabytes of the audit log file before it gets rotated
maxFileSize: 200
# maxFiles is the maximum number of rotated audit log files to retain
Expand Down
2 changes: 1 addition & 1 deletion pkg/config/apiserver.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ type NamedCertificateEntry struct {

type AuditLog struct {
// maxFileAge is the maximum number of days to retain old audit log files
// +kubebuilder:default=10
// +kubebuilder:default=0
MaxFileAge int `json:"maxFileAge"`
// maxFiles is the maximum number of rotated audit log files to retain
// +kubebuilder:default=10
Expand Down
7 changes: 6 additions & 1 deletion pkg/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,12 @@ func (c *Config) fillDefaults() error {
URL: "https://localhost:6443",
Port: 6443,
}
c.ApiServer.AuditLog.Profile = "Default"
c.ApiServer.AuditLog = AuditLog{
MaxFileAge: 0,
MaxFiles: 10,
MaxFileSize: 200,
Profile: "Default",
}
c.Node = Node{
HostnameOverride: hostname,
NodeIP: nodeIP,
Expand Down