Hi There any way to archive the data offline before it is deleted. We want to delete the workflow runs for reducing the GitHub storage. If you yes please mention the answer ASAP.
@@CoderDave yes, but what if my action is added in only this new branch ? I've been reading at SO that then GH CLI is needed to run this action - quite strange
Hi. Is there a way to restrict manually triggering of a workflow? Because anyone with access to the github project can trigger it. Is there a way to show Run workflow button to selected users?
Hey, unfortunately there is no real way to restrict that. Any user with Write access to a repo (Collaborators, Admins, Owners) can trigger the `workflow_dispatch` event.
not sure if this is what you mean, but you cannot combine triggers to act at the same time. You can add both the push and the workflow_dispatch... but what that does is running the action on every push + additionally letting you start it manually when no push occurs
hi, good video,. my question is : if I have run this workflow on push event or pull request event it doesnt take default values I try to print this but print empty , how can do that ?, thanks my bro
Thanks. Unfortunately the parameters work only when you trigger the workflow manually. There is no way to have parameters on a push or pr trigger. The only way you could achieve that is this workaround: 1) set some variables in the workflow with the default value you want to use 2) add a task that check if the parameters have value, and if they do change the value of the variables 3) in the rest of the workflow use the variables instead of the parameters
As long as you have the actions file on the master branch, then you can run it on other branches.... but if that file has never been on master, then unfortunately you can't :(
Could you please share the code about how to select multiple values from the drop in the below yaml file from github actions UI(workflow dispatch) , with the current yaml file UI will allow 1 value from the options tag(for eg login:ocean , cypress:all_ocean) name: Invoking automation scripts on: workflow_dispatch: inputs: Applications: type: choice description: Select the application options: [IAM] TestSuites: type: choice description: Select the Test Suite required: true options: - login:ocean - cypress:all_ocean - cypress:all_scm - cypress:all_sealand - changePassword:ocean
@@CoderDave Thanks for responding to my comment. I could only see the manual trigger option only when i add workflow dispatch in default branch. If i remove from default I don’t see it anymore.
Wow! This is awesome!!! Thank you!
Yes, I’m super excited about that feature! Thanks to you 😊
It Works, Thanks for the info. I have been searching this for 2days
Happy to know it ☺️
✨ *Question of the day* ✨: How much do you like this new feature? 😁
Cool. Thanks for sharing.
No problem!
Thank you!
You're welcome!
Hi
There any way to archive the data offline before it is deleted. We want to delete the workflow runs for reducing the GitHub storage.
If you yes please mention the answer ASAP.
Hey there. AFAIK there isn’t a way
Thanks bro, you helped me on cicd
Glad to hear it
How to run a workflow created on a non-master branch from the workflow_dispatch event ?
You can select the branch in the dropdown of the "Run Workflow" button. OR, if you are doing via API, se the `ref ` parameter in the request body
@@CoderDave yes, but what if my action is added in only this new branch ? I've been reading at SO that then GH CLI is needed to run this action - quite strange
Helped! Thank you so much, i was trying to fix it all day:)
Great to know! ☺️
Thanks for the video.... just what i was looking for !
Happy it’s been useful 😊
Hi. Is there a way to restrict manually triggering of a workflow?
Because anyone with access to the github project can trigger it. Is there a way to show Run workflow button to selected users?
Hey, unfortunately there is no real way to restrict that. Any user with Write access to a repo (Collaborators, Admins, Owners) can trigger the `workflow_dispatch` event.
@@CoderDave ok, thanks for the reply.
I can't find how to stack it with push (on push, but with manual trigger)
not sure if this is what you mean, but you cannot combine triggers to act at the same time. You can add both the push and the workflow_dispatch... but what that does is running the action on every push + additionally letting you start it manually when no push occurs
hi, good video,. my question is : if I have run this workflow on push event or pull request event it doesnt take default values I try to print this but print empty , how can do that ?, thanks my bro
Thanks. Unfortunately the parameters work only when you trigger the workflow manually. There is no way to have parameters on a push or pr trigger.
The only way you could achieve that is this workaround:
1) set some variables in the workflow with the default value you want to use
2) add a task that check if the parameters have value, and if they do change the value of the variables
3) in the rest of the workflow use the variables instead of the parameters
this only works if you push to master branch, we don't have access to commit to master at work, can we test the trigger by using any other branch?
As long as you have the actions file on the master branch, then you can run it on other branches.... but if that file has never been on master, then unfortunately you can't :(
how can I do this on a forked repo
Same way as normal repos. Just add or edit the workflow yaml file and your done 😉
Could you please share the code about how to select multiple values from the drop in the below yaml file from github actions UI(workflow dispatch) , with the current yaml file UI will allow 1 value from the options tag(for eg login:ocean , cypress:all_ocean)
name: Invoking automation scripts
on:
workflow_dispatch:
inputs:
Applications:
type: choice
description: Select the application
options: [IAM]
TestSuites:
type: choice
description: Select the Test Suite
required: true
options:
- login:ocean
- cypress:all_ocean
- cypress:all_scm
- cypress:all_sealand
- changePassword:ocean
Unfortunately it is not possible to have a multi select as input parameter. Only a single value for each field
@@CoderDave : Thank you for your reply , could you please help me with some arounds or any other suggestion which would help me to proceed further
It is not working for feature branches.
Hi, not sure what you mean. When you trigger the workflow manually, you can choose the branch you want it to run on.
@@CoderDave Thanks for responding to my comment. I could only see the manual trigger option only when i add workflow dispatch in default branch. If i remove from default I don’t see it anymore.
@@anilnidamanuri3753 yes, unfortunately im trying to find an alternative to it too
yesh
😀
does not work ok
What do you mean doesn’t work? I’m using this on daily basis 😅
@@CoderDave --hello thxz for the reply but it doesnt work fo rme it seems my dockerfile is not properly configured not sure thxz anywayLisa
Wait… what dockerfile ? This is native of the GitHub actions engine…