Skip to content

CICD-229 · Long-running job management ​

Encyclopedia · Advanced workflow orchestration · All snippets

Previous · CICD-228 · Next · CICD-230

1. Where it fits ​

  • Placement scripts/long-check.sh.
  • Prerequisites authenticated GitHub CLI, approved target repositories, or Actions runner for YAML entries.
  • Platforms local-linux, github-actions, gitea-actions.

2. Copy the snippet ​

bash
timeout --signal=TERM --kill-after=15s 12m ./scripts/integration.sh

3. How it works ​

timeout first signals the long-running check to stop and escalates after a grace period. The integration script should still handle cleanup on a signal.

4. Verify the result ​

Use GNU timeout in a Linux runner and an integration script with cleanup traps. A normal timeout exits 124.

Validation syntax-validated (Bash parse). Status definitions.