When reviewing an action for use, what file defines its available inputs and outputs?
Answer(s): E
A custom GitHub Action's inputs, outputs, and other configurations are defined in its metadata file, which must be named action.yml or action.yaml and placed at the root of the action's repository. This YAML file specifies how the action runs (e.g., using Docker or JavaScript) and provides the metadata for its inputs and outputs, which are then used by workflows that call the action.Key aspects of the action.yml or action.yaml fileFormat: It uses YAML syntax.Location: It must be in the root directory of your action's repository.Contents: It defines the action's name, description, inputs, outputs, and the runs configuration to specify the execution environment (like a Docker image or JavaScript file) and entrypoint.Inputs and Outputs: The file includes inputs and outputs sections to declare the data the action accepts and produces, respectively.
https://docs.github.com/en/actions/reference/workflows-and-actions/metadata-syntax
Which of the following statements are true regarding the use of GitHub Actions on a GitHub Enterprise Server instance? (Each correct answer presents a complete solution. Choose three.)
Answer(s): B,C,F
[B] If you want your GitHub Enterprise Server instance to use third-party custom actions, you need to enable GitHub Connect.[C] Most official GitHub-authored actions are automatically bundled with GitHub Enterprise Server, and are captured at a point in time from GitHub Marketplace.[F] Third-party actions can be manually synchronized to GitHub Enterprise Server (GHES) to be used in workflows without requiring an internet connection to GitHub.com. This is done using the actions-sync tool to download actions from GitHub.com and transfer them to the GHES instance. This manual method provides an alternative to using GitHub Connect, offering stricter control over which actions are available on the GHES instance.Incorrect:[Not D] There is no connection required between your GitHub Enterprise Server instance and GitHub.com to use these actions.
https://docs.github.com/en/enterprise-server@3.17/get-started/exploring-integrations/about-using-integrations https://docs.github.com/en/enterprise-server@3.17/admin/managing-github-actions-for-your-enterprise/managi ng-access-to-actions-from-githubcom/about-using-actions-in-your-enterprise
You need to use a specific version of an action. How should you use v1 of an actions/javascript-action repository in your workflow?
Answer(s): D
The appropriate code to use version v1 of the actions/javascript-action repository in your GitHub Actions workflow is uses: actions/javascript-action@v1.Workflow ImplementationYou implement this code within a specific step under a job in your workflow YAML file (located in .github/workflows/):jobs:my_job:runs-on: ubuntu-latest steps:- name: Run JavaScript Action uses: actions/javascript-action@v1
https://docs.github.com/en/organizations/managing-organization-settings/disabling-or-limiting-github-actions-fo r-your-organization
What is a role of GitHub Marketplace when using GitHub Actions workflows?
Answer(s): B
The GitHub Marketplace is primarily a platform for finding and sharing public actions, apps, and workflows with the entire GitHub community.Incorrect:[Not C]The GitHub Marketplace is primarily a platform for finding and sharing public actions, apps, and workflows with the entire GitHub community. It is not the native platform for hosting workflows that are shared privately within an organization.How to Share Workflows PrivatelyRather than using the Marketplace, you can manage internal sharing through these methods:Internal Repositories: You can store reusable workflows or actions in an internal repository. This makes them visible and usable by any other repository within the same organization or enterprise without making them public.Private Repository Access: You can configure a private repository to allow access from other specific repositories or all repositories within your organization.Reusable Workflows: By defining a workflow with the on: workflow_call trigger, you can reference it from other repositories using the owner/repo/path/to/workflow.yml@ref syntax.Organizational Policies: Administrators can set policies at the organization or enterprise level to allow only internal actions, or a specific "allow list" of verified Marketplace actions.
https://www.geeksforgeeks.org/git/what-is-github-marketplace/
What is the proper syntax to reference the system-provided run number variable?
Default environment variablesThe default environment variables that GitHub sets are available to every step in a workflow.Because default environment variables are set by GitHub and not defined in a workflow, they are not accessible through the env context [Not B]. However, most of the default variables have a corresponding, and similarly named, context property. For example, the value of the GITHUB_REF variable can be read during workflow processing using the ${{ github.ref }} context property.
https://docs.github.com/en/actions/reference/workflows-and-actions/variables
Post your Comments and Discuss Microsoft GH-200 exam prep with other Community members: