Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

default to stdout in readinessProbe, wip configuration for it #1541

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from
Draft
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
8 changes: 8 additions & 0 deletions api/v1/mongodbcommunity_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,9 @@ type MongoDBCommunitySpec struct {
// AgentConfiguration sets options for the MongoDB automation agent
// +optional
AgentConfiguration AgentConfiguration `json:"agent,omitempty"`
// AgentConfiguration sets options for the MongoDB readiness probe
// +optional
ReadinessProbeConfiguration ReadinessProbeConfiguration `json:"readiness,omitempty"`

// AdditionalMongodConfig is additional configuration that can be passed to
// each data-bearing mongod at runtime. Uses the same structure as the mongod
Expand Down Expand Up @@ -377,6 +380,11 @@ type AgentConfiguration struct {
SystemLog *automationconfig.SystemLog `json:"systemLog,omitempty"`
}

type ReadinessProbeConfiguration struct {
// +optional
LogFile string `json:"logFile"` // if this is set, we should set LOG_FILE_PATH for the readinessProbe env var
}

// StatefulSetSpecWrapper is a wrapper around StatefulSetSpec with a custom implementation
// of MarshalJSON and UnmarshalJSON which delegate to the underlying Spec to avoid CRD pollution.

Expand Down
2 changes: 1 addition & 1 deletion pkg/readiness/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ const (
DefaultAgentHealthStatusFilePath = "/var/log/mongodb-mms-automation/agent-health-status.json"
AgentHealthStatusFilePathEnv = "AGENT_STATUS_FILEPATH"

defaultLogPath = "/var/log/mongodb-mms-automation/readiness.log"
defaultLogPath = "/dev/stdout"
podNamespaceEnv = "POD_NAMESPACE"
automationConfigSecretEnv = "AUTOMATION_CONFIG_MAP" //nolint
logPathEnv = "LOG_FILE_PATH"
Expand Down
2 changes: 1 addition & 1 deletion release.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"golang-builder-image": "golang:1.21",
"operator": "0.9.0",
"version-upgrade-hook": "1.0.8",
"readiness-probe": "1.0.18",
"readiness-probe": "1.0.19",
"agent": "107.0.1.8507-1",
"agent-tools-version": "100.9.4"
}
Loading