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

Kubernetes: Don't set activeDeadlineSeconds by default #2452

Merged
merged 1 commit into from
Jul 9, 2018
Merged
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
6 changes: 4 additions & 2 deletions luigi/contrib/kubernetes.py
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ def active_deadline_seconds(self):
Time allowed to successfully schedule pods.
See: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/#job-termination-and-cleanup
"""
return 100
return None

@property
def kubernetes_config(self):
Expand Down Expand Up @@ -329,7 +329,6 @@ def run(self):
}
},
"spec": {
"activeDeadlineSeconds": self.active_deadline_seconds,
"backoffLimit": self.backoff_limit,
"template": {
"metadata": {
Expand All @@ -339,6 +338,9 @@ def run(self):
}
}
}
if self.active_deadline_seconds is not None:
job_json['spec']['activeDeadlineSeconds'] = \
self.active_deadline_seconds
# Update user labels
job_json['metadata']['labels'].update(self.labels)
# Add default restartPolicy if not specified
Expand Down