Creating GitHub Actions

New release: GitHub Actions is now available in a new limited public beta. This version offers a new workflow configuration and built-in continuous integration and continuous deployment capabilities. We strongly recommend you avoid using it for high-value workflows and content during this public beta period. To request to join the limited public beta, see the GitHub Actions page. For more information, see "About GitHub Actions" in the GitHub Help documentation.

GitHub Support will only provide support for the YAML syntax and no longer provides support for the HCL syntax.

If you participated in the limited public beta and created workflows with the HCL syntax GitHub Actions, you will need to upgrade to the new limited public beta that uses YAML syntax. When your repository is eligible to upgrade, you'll see an invitation in your repository. You must accept the invitation before you can use the new limited public beta.

Once you've upgraded, any workflows that you created with the HCL syntax will need to be updated to the new YAML syntax. To automatically convert your workflows, see "Migrating GitHub Actions from HCL syntax to YAML syntax" in the GitHub Help documentation.

GitHub Actions are code run in Docker containers. The Docker container executes in a runtime environment that gives the action access to a filesystem and environment variables. You can set customized secrets and environment variables for each action you include in your workflow. GitHub also sets some environment variables for an action to use. Production secrets should not be stored in the API during the limited public beta period.

GitHub Actions are event-driven. When an event triggers a workflow, each action executes in the order defined by the workflow. An action can't trigger other workflows. See "Workflow limitations" for more details.

You can create your own actions in a repository, use actions in a public GitHub repository, and use actions in a published Docker container image. Use or extend actions in the GitHub Marketplace or one of GitHub's pre-built actions, which perform common GitHub workflows like deploying code and publishing npm modules.

Creating a new action

You can create actions in a repository you own by adding a Dockerfile. To share GitHub Actions with the GitHub community, your repository must be public.

Creating a Docker container

GitHub Actions execute in Docker containers. An action can use an existing publicly available Docker image, or you can create your own Docker image by including a Dockerfile with your code.

Accessing the runtime environment

GitHub Actions execute in a runtime environment with access to a filesystem and environment variables to perform tasks.