Skip to content

Commit

Permalink
Add argument termination_grace_period_seconds (#58)
Browse files Browse the repository at this point in the history
  • Loading branch information
abhinavclemson authored Jan 18, 2024
1 parent 8ca35b0 commit 8897ac8
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions xpk.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@
priorityClassName: {args.priority}
hostNetwork: true
dnsPolicy: ClusterFirstWithHostNet
terminationGracePeriodSeconds: {args.termination_grace_period_seconds}
containers:
{container}
volumeMounts:
Expand Down Expand Up @@ -2994,6 +2995,16 @@ def directory_path_type(value):
),
)

workload_create_parser_optional_arguments.add_argument(
'-tgps', '--termination-grace-period-seconds',
type=str,
default='30',
help=(
'Maximum wait time for a workload Pod to wrap up after a disruption event or deletion request.'
'Defaults to 30 seconds.'
),
)

workload_create_parser.set_defaults(func=workload_create)

# "job delete" command parser.
Expand Down

0 comments on commit 8897ac8

Please sign in to comment.