본문으로 바로가기 본문 바로가기
WIKI 기술 지식 베이스

크론 트리거

원문 보기 위키 갱신

크론 트리거 (Cron Trigger)

Drone REST API의 크론 작업 트리거 엔드포인트를 설명하는 문서예요. 등록된 크론 작업을 즉시 실행해 새 빌드를 만듭니다.

출처: Drone CI Docs

본문

기존 크론 작업을 트리거해요. 이 API는 해당 저장소에 대한 쓰기 권한을 필요로 한다는 점에 유의하세요.

POST /api/repos/{owner}/{repo}/cron/{name}

응답 본문 예시:

{
  "id": 100207,
  "repo_id": 296163,
  "trigger": "@cron",
  "number": 42,
  "status": "pending",
  "event": "cron",
  "action": "",
  "link": "https://github.com/octocat/hello-world/compare/e3320539a4c0...9fc1ad6ebf12",
  "timestamp": 0,
  "message": "updated README",
  "before": "",
  "after": "9fc1ad6ebf12462f3f9773003e26b4c6f54a772e",
  "ref": "refs/heads/master",
  "source_repo": "",
  "source": "",
  "target": "master",
  "author_login": "octocat",
  "author_name": "The Octocat",
  "author_email": "octocat@github.com",
  "author_avatar": "http://www.gravatar.com/avatar/7194e8d48fa1d2b689f99443b767316c",
  "sender": "octocat",
  "cron": "weekly-update-check",
  "started": 0,
  "finished": 0,
  "created": 1609336029,
  "updated": 1609336029,
  "version": 1
}