Skip to content

Commit

Permalink
Merge pull request #343 from fmount/enable_image_cache
Browse files Browse the repository at this point in the history
Replace DBPurge Debug boolean with CronJob
  • Loading branch information
openshift-ci[bot] authored Oct 13, 2023
2 parents d168c77 + 7c57137 commit a07d827
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion api/bases/glance.openstack.org_glances.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ spec:
type: string
debug:
properties:
dbPurge:
cronJob:
default: false
type: boolean
dbSync:
Expand Down
4 changes: 2 additions & 2 deletions api/v1beta1/glance_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -147,8 +147,8 @@ type GlanceDebug struct {
DBSync bool `json:"dbSync"`
// +kubebuilder:validation:Optional
// +kubebuilder:default=false
// DBPurge enable debug
DBPurge bool `json:"dbPurge"`
// CronJob enable debug
CronJob bool `json:"cronJob"`
}

// GlanceStatus defines the observed state of Glance
Expand Down
2 changes: 1 addition & 1 deletion config/crd/bases/glance.openstack.org_glances.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ spec:
type: string
debug:
properties:
dbPurge:
cronJob:
default: false
type: boolean
dbSync:
Expand Down
2 changes: 1 addition & 1 deletion pkg/glance/cronjob.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ func CronJob(
var cronCommand []string = cronJobCommand[:]
args := []string{"-c"}

if !instance.Spec.Debug.DBPurge {
if !instance.Spec.Debug.CronJob {
// If debug mode is not requested, remove the --debug option
cronCommand = append(cronJobCommand[:1], cronJobCommand[2:]...)
}
Expand Down

0 comments on commit a07d827

Please sign in to comment.