Github Actions

 Github Actions consists of 3 different units.

Step ⊂ Job ⊂ Workflow


1. Workflow

Workflow is the biggest unit for the Github Actions. It consists of a single yml file. It defines when the workflow should be run; which file, which branch, which command and so on. It contains one or more jobs, and different workflows run in parallel.


2. Job

Jobs are the chunk of the steps which is for certain purpose like test, build, or deploy. It defines the environment in which the steps should be run and permissions the GITHUB_TOKEN which the steps have. Different jobs run in parallel by default, but you can make them run in sequence using 'needs' keyword: if job A has job B in its 'needs', job A runs after the job B is completed.

*GITHUB_TOKEN is the access token that  is used to access your Github Apps like contents, page, and metadata.


3. Step

Steps are the commands that defines the actual actions. It can defined in the way of terminal command or other keywords. You can type terminal command using 'run' like 'run: ./gradlew build' or can use pre-defined command that the GitHub offers like 'uses' to reference a specific metadata of your project like '- uses: actions/checkout@main' or other external actions.

댓글

이 블로그의 인기 게시물

Interface of Java

Data Analytics Overview(OLTP vs OLAP)

Leetcode