github workflow

GITHUB WORKFLOW  KEYS

on:

events that will trigger the workflow.  This event will only trigger a workflow run if the workflow file exists on the default branch.

https://docs.github.com/en/webhooks/webhook-events-and-payloads

Webhook event payload : types

workflow_dispatch : manual run

push

repository_dispatch

branch_protection_rule : [created,edited, deleted], GITHUB_SHA(last commit) ,GITHUB_REF(default branch)

check_run : [created,rerequested,completed,requested_action]

check_suite : [completed] 

create,delete,

Runs your workflow when someone creates a Git reference (Git branch or tag) in the workflow's repository 

deployment

deployment_status

discussion

fork

gollum : wiki page edits 

issue_comment,label : [created,edited, deleted]

issues : [opened  edited  deleted  transferred  pinned unpinned  closed  reopened assigned unassigned  labeled  unlabeled  locked  unlocked milestoned demilestoned  typed  untyped] 

  page_build

 pull_request

pull_request_review_comment

workflow_run : [ completed  requested  in_progress] 

workflow_call
 

 

schedule:  

posix cron item, minute,hour,day-month,month,day-week(sunday:-0:saturday:-6)

*=any value ,=separator, -=range of value /=step value i.e x/y=step of y added to x

https://crontab.guru/

 

condition

    if: github.repository == 'octo-org/octo-repo-prod'

 

 

runs-on

https://docs.github.com/en/actions/writing-workflows/choosing-where-your-workflow-runs/choosing-the-runner-for-a-job

16 gb ram 14gb ssd, 4 cpu, 

ubuntu-latest, ubuntu-24.04, ubuntu-22.04, ubuntu-20.04, ubuntu-24.04-arm, ubuntu-22.04-arm

windows-latest, windows-2025[Public preview], windows-2022, windows-2019 

macos-13

macos-latest, macos-14, macos-15  = m1 chip , 3 cpu, 7 gb ram

 

Container

image: 

env:

ports:

volumes:

options: docter container options: https://docs.docker.com/reference/cli/docker/container/create/#options

no --network and --entrypoint options

steps;

credentials:

 

if used only container without option use like container:

 

 uses: docker://alpine:3.8

 uses: docker://ghcr.io/OWNER/IMAGE_NAME

 

jobs:

 it need either runs-on or uses , each of job will execute on a runner machine and run a series of one or more steps.

 

steps:

Each step can either run a script that you define or run an action, which is a reusable extension that can simplify your workflow.

 

steps must be alist and yaml syntax for list is - 

 

 

 

 

 

Comments

Popular posts from this blog

xdm linux merge incomplete download parts

kde on debian

fedora install from container tarball