GitHub Actions
GitHub Actionsは、GitHubが提供するCI/CDサービスである。
| 開発元 | GitHub |
|---|---|
| 種別 | 継続的インティグレーション/継続的デリバリー |
| 公式サイト |
(日)github |
GitHubと高度に統合されており、GitHubに公開されたコードを自動でビルド・テスト・デプロイを行うのが主目的である。
要素
GitHub Actionsは複数の要素から構成される。
Action
GitHub Actionsにおける action はstepとして利用可能なプログラムである。実体は以下のいずれかである[3]。
- Docker container
- JavaScript
- Composite Actions: 他actionの集まり
例えばJavaScript actionsであれば設定ファイルで実行Node.js環境を指定した上で、所定のJavaScriptファイルが自動実行される。Node.jsのバージョンはメタデータの runs.using を用いて指定され、2023-02現在、node12 と node16 の2種類が指定できる[4](node12 は廃止予定)。
設定
リポジトリの .github/workws以下にYAML形式の設定ファイルを記述することで設定を行う。
設定はワークフローとアクションという単位で行われる。
ワークフロー
設定ファイルの基本単位。イベントが起きたときに実行する処理を記述しておく。
脚注
- "A job is a set of steps in a workflow that execute on the same runner." GitHub. Understanding GitHub Actions. 2023-02-18閲覧.
- "Each step is either a shell script that will be executed, or an action that will be run." GitHub. Understanding GitHub Actions. 2023-02-18閲覧.
- "You can build Docker container, JavaScript, and composite actions." GitHub. Understanding GitHub Actions. 2023-02-18閲覧.
- "
runs.usingfor JavaScript actions" GitHub. Metadata syntax for GitHub Actions. 2023-02-18閲覧. - “GitHub Actions” (英語). GitHub. 2020年5月21日閲覧。
外部リンク
This article is issued from Wikipedia. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.