repository-dispatch | A GitHub action to create a repository dispatch event | Continous Integration library
kandi X-RAY | repository-dispatch Summary
kandi X-RAY | repository-dispatch Summary
A GitHub action to create a repository dispatch event.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of repository-dispatch
repository-dispatch Key Features
repository-dispatch Examples and Code Snippets
Community Discussions
Trending Discussions on repository-dispatch
QUESTION
From the GH Rest API docs, seems we're able to create a repository_dispatch
event, but no workflow_dispatch
event. In the GH GraphQL API, I couldn't find how to dispatch events.
Is it even possible to trigger a workflow_dispatch
event using the API?
ANSWER
Answered 2021-Nov-29 at 17:18Yes, it's possible, manually or through the Github API.
Manually (through theActions
tab on your repository.)
Here is an official documentation about it
Basically, once you select the workflow on the tab, if the workflow implementation has the workflow_dispatch trigger, the option Run workflow
will appear on the right part of the window, like this:
On the official Github Documentation, there is a service to create a workflow dispatch event
Here is a curl example:
QUESTION
I want to create a simple Github Action that logs a timestamp to a log file, to something like /logs/publish.log
I need the github action to trigger from a webhook.
My github action would upon receiving a webhook request.
- Append the date/time to the end of /logs/publish.log
- Do an automatic commit eg "Newly published content"
How would I configure a github action to achieve this?
Here's where I'm at as a start:
File: .github/workflows/log-commit-on-repository-dispatch.yml
...ANSWER
Answered 2020-Nov-19 at 04:30I got the essence of this solved with the clue provided by riQQ. actions/checkout@v2 provided almost the exact code I needed in their example code to Push a commit using the built-in token
.github/workflows/publish.yml
QUESTION
Is there a way to pass data securely from between repos using the client_payload
in a repository dispatch event?
I create a repository dispatch event for a CI pipeline I have between my two of my repos. My first repo uses Terraform in a GitHub Action to create Azure cloud resources and then is suppose to take the outputs for the sever address, username, and password of my container registry resource created using my azure.tf
script.
In the final step of my GitHub Action in the first repo, it makes a POST request curl
to notify my second repo that the initial cloud resources for the Azure Container Registry (ACR) have been created. It should now be safe to build my container images from my second repo and push them to ACR.
My problem is with the client_payload
being sent over to my second repo, it is using unsecure raw json that will expose the password most importantly and other information in the output string of my running CI jobs under the GitHub action in my second repo.
This is why I'd like to understand if there's a way to pass data securely from between repos using the client_payload
?
ANSWER
Answered 2020-Jul-12 at 21:39Github Action recently launched something called organization secrets. That would be a better way to handle the service account credentials (assuming you are using service accounts).
Manually trigger workflowIf you don't have service account setup, then the most recent workflow_dispatch
offering might be a better fit.
Workflow
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install repository-dispatch
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page