Skip to content

Commit 555b41a

Browse files
committed
set years suffix to y
Signed-off-by: iTrooz <[email protected]>
1 parent 4cac3c3 commit 555b41a

File tree

5 files changed

+6
-5
lines changed

5 files changed

+6
-5
lines changed

config/crd/v1/bases/velero.io_backups.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -498,7 +498,7 @@ spec:
498498
TTL is a time.Duration-compatible string describing how long
499499
the Backup should be retained for.
500500
Supports time.Duration units + day (d), week (w), month (mo), and year (yr).
501-
Note that days, months, and years are static durations: 1d = 24h, 1mo = 30d, 1yr = 365d.
501+
Note that days, months, and years are static durations: 1d = 24h, 1mo = 30d, 1y = 365d.
502502
type: string
503503
uploaderConfig:
504504
description: UploaderConfig specifies the configuration for the uploader.

config/crd/v1/bases/velero.io_schedules.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -539,7 +539,7 @@ spec:
539539
TTL is a time.Duration-compatible string describing how long
540540
the Backup should be retained for.
541541
Supports time.Duration units + day (d), week (w), month (mo), and year (yr).
542-
Note that days, months, and years are static durations: 1d = 24h, 1mo = 30d, 1yr = 365d.
542+
Note that days, months, and years are static durations: 1d = 24h, 1mo = 30d, 1y = 365d.
543543
type: string
544544
uploaderConfig:
545545
description: UploaderConfig specifies the configuration for the

config/crd/v1/crds/crds.go

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/apis/velero/v1/backup_types.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ type BackupSpec struct {
111111
// TTL is a time.Duration-compatible string describing how long
112112
// the Backup should be retained for.
113113
// Supports time.Duration units + day (d), week (w), month (mo), and year (yr).
114-
// Note that days, months, and years are static durations: 1d = 24h, 1mo = 30d, 1yr = 365d.
114+
// Note that days, months, and years are static durations: 1d = 24h, 1mo = 30d, 1y = 365d.
115115
// +optional
116116
TTL metav1.Duration `json:"ttl,omitempty"`
117117

pkg/cmd/util/flag/duration.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ var unitMap = map[string]uint64{
2828
"d": uint64(24 * time.Hour),
2929
"w": uint64(7 * 24 * time.Hour),
3030
"mo": uint64(30 * 24 * time.Hour),
31+
"y": uint64(365 * 24 * time.Hour),
3132
"yr": uint64(365 * 24 * time.Hour),
3233
}
3334

0 commit comments

Comments
 (0)