Skip to content
GitLab
Next
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • GitLab GitLab
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Issues 44,758
    • Issues 44,758
    • List
    • Boards
    • Service Desk
    • Milestones
    • Iterations
    • Requirements
  • Merge requests 1,331
    • Merge requests 1,331
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
    • Test Cases
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Container Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Metrics
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Code review
    • Insights
    • Issue
    • Repository
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • GitLab.orgGitLab.org
  • GitLabGitLab
  • Issues
  • #14887
Closed
Open
Issue created Jan 16, 2016 by g@wgordonw1

Specify timeout per job in .gitlab-ci.yml

Problem to Solve

Different jobs have different execution characteristics, but the timeout on a per-job basis is not configurable. It would be very nice to be able to override the project default timeout specified in project settings in the projects ci config file.

Use Case

One example would be pushing docker image to remote repo. As part of a deploy process a docker image is pushed to a remote registry over a slow connection. As such, if the docker image is large, the job can take over an hour to complete. However, I don't want to set the project default timeout to something like 5 hours because all of the other jobs defined in the .gitlab-ci.yml config file complete much quicker and letting them stall for 5 hours would be too long.

Proposal

# .gitlab-ci.yml
timeout: 60 # timeout in minutes

build_job:
  timeout: 30

deploy_job:
  timeout: 180

Limitations

  • It should not be possible to specify a timeout longer than an instance-wide or runner-configured maximum timeout, otherwise it becomes an abuse vector for GitLab.com.
Edited Jun 18, 2019 by Jason Yavorska
Assignee
Assign to
Time tracking