Co-authored-by: Josh Gross <joshmgross@github.com> Co-authored-by: Brian Cristante <33549821+brcrista@users.noreply.github.com> Co-authored-by: John Bohannon <imjohnbo@github.com> Co-authored-by: Lucas Costi <lucascosti@users.noreply.github.com>
58 lines
2.9 KiB
Markdown
58 lines
2.9 KiB
Markdown
---
|
|
title: Reference
|
|
intro: 'Reference documentation for creating workflows, using GitHub-hosted runners, and authentication.'
|
|
redirect_from:
|
|
- /actions/configuring-and-managing-workflows/using-variables-and-secrets-in-a-workflow
|
|
versions:
|
|
free-pro-team: '*'
|
|
enterprise-server: '>=2.22'
|
|
---
|
|
|
|
{% data reusables.actions.enterprise-beta %}
|
|
{% data reusables.actions.enterprise-github-hosted-runners %}
|
|
|
|
### Workflow syntax
|
|
|
|
The workflow file is written in YAML. In the YAML workflow file, you can use expression syntax to evaluate contextual information, literals, operators, and functions. Contextual information includes workflow, environment variables, secrets, and the events that triggered the workflow. When you use [`run`](/actions/reference/workflow-syntax-for-github-actions#jobsjob_idstepsrun) in a workflow step to run shell commands, you can use specific workflow command syntax to set environment variables, set output parameters for subsequent steps, and set error or debug messages.
|
|
|
|
{% link_in_list /workflow-syntax-for-github-actions %}
|
|
{% link_in_list /context-and-expression-syntax-for-github-actions %}
|
|
{% link_in_list /workflow-commands-for-github-actions %}
|
|
|
|
### Events
|
|
|
|
You can configure workflows to run when specific GitHub events occur, at a scheduled time, manually, or when events outside of GitHub occur.
|
|
|
|
{% link_in_list /events-that-trigger-workflows %}
|
|
|
|
### Authentication and secrets
|
|
|
|
{% data variables.product.prodname_dotcom %} provides a token that you can use to authenticate on behalf of {% data variables.product.prodname_actions %}. You can also store sensitive information as a secret in your organization{% if currentVersion == "free-pro-team@latest" or currentVersion ver_gt "enterprise-server@3.0" %}, repository, or environments{% else %} or repository{% endif %}. {% data variables.product.prodname_dotcom %} encrypts all secrets.
|
|
|
|
{% link_in_list /authentication-in-a-workflow %}
|
|
{% link_in_list /encrypted-secrets %}
|
|
|
|
{% if currentVersion == "free-pro-team@latest" or currentVersion ver_gt "enterprise-server@3.0" %}
|
|
### Environments
|
|
|
|
Workflow jobs can reference environments that have protection rules or environment-specific secrets.
|
|
|
|
{% link_in_list /environments %}
|
|
{% endif %}
|
|
|
|
### {% data variables.product.prodname_dotcom %}-hosted runners
|
|
|
|
GitHub offers hosted virtual machines to run workflows. The virtual machine contains an environment with tools, packages, and environment variables for GitHub Actions to use.
|
|
|
|
{% link_in_list /environment-variables %}
|
|
{% link_in_list /specifications-for-github-hosted-runners %}
|
|
|
|
{% if currentVersion == "free-pro-team@latest" %}
|
|
### Administration
|
|
|
|
When you run workflows on {% data variables.product.prodname_dotcom %}-hosted runners, there are usage limits and potential usage charges. You can also disable or restrict the usage of {% data variables.product.prodname_actions %} in a repository and organization.
|
|
|
|
{% link_in_list /usage-limits-billing-and-administration %}
|
|
|
|
{% endif %}
|