Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/birajmainali/bulk-github-action-runner
Automate GitHub Actions workflows across multiple projects and branches using Puppeteer. Configurable, browser-driven CI/CD solution for GitHub organizations. #Automation #Puppeteer #GitHubActions #CI/CD #NodeJS
https://github.com/birajmainali/bulk-github-action-runner
actions browser-automation bulk-actions bulk-github-action-runner bulk-github-workflow-runner github microservices microserviecs-deployment workflows
Last synced: 16 days ago
JSON representation
Automate GitHub Actions workflows across multiple projects and branches using Puppeteer. Configurable, browser-driven CI/CD solution for GitHub organizations. #Automation #Puppeteer #GitHubActions #CI/CD #NodeJS
- Host: GitHub
- URL: https://github.com/birajmainali/bulk-github-action-runner
- Owner: BirajMainali
- Created: 2024-10-29T09:05:13.000Z (20 days ago)
- Default Branch: master
- Last Pushed: 2024-10-30T15:29:55.000Z (18 days ago)
- Last Synced: 2024-10-30T16:31:09.276Z (18 days ago)
- Topics: actions, browser-automation, bulk-actions, bulk-github-action-runner, bulk-github-workflow-runner, github, microservices, microserviecs-deployment, workflows
- Language: JavaScript
- Homepage:
- Size: 30.3 KB
- Stars: 0
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Bulk GitHub Action Runner
This project automates the execution of multiple GitHub Actions workflows across various projects and branches using [Puppeteer](https://pptr.dev/), enabling streamlined workflow management from the command line.
## Features
- Initiates workflows for specific branches (`develop` or `master`) as configured.
- Automates GitHub Actions for multiple projects within an organization.
- Configurable with `config.json` for project details, workflows, branches, and browser settings.
- Launches a Chrome/Chromium instance for browser-based UI automation.## Prerequisites
- [Node.js](https://nodejs.org/) (v12 or higher)
- [Puppeteer](https://pptr.dev/)## Installation
1. **Clone the Repository**:
```bash
git clone https://github.com/BirajMainali/bulk-github-action-runner.git
cd bulk-github-action-runner
```2. **Install Dependencies**:
```bash
npm install
```3. **Configure `config.json`**:
Create a `config.json` file in the root directory using the following structure:```json
{
"browser": {
"executablePath": "C:\\Program Files\\Google\\Chrome\\Application\\chrome.exe",
"userDataDir": "C:\\Users\\{{Your Name}}\\AppData\\Local\\Google\\Chrome\\User Data"
},
"supportedBranches": ["develop", "master"],
"organization": "organization-name",
"projects": [
{
"name": "project-name",
"workflows": {
"develop": ["build-dev", "deploy-dev"],
"master": ["deploy.yml"]
}
}
]
}
```- **`browser.executablePath`**: Path to your Chrome/Chromium executable.
- **`browser.userDataDir`**: Path to your Chrome user data directory (to retain login sessions).
- **`supportedBranches`**: List of branches where workflows can run (e.g., `develop`, `master`).
- **`organization`**: Your GitHub organization or username.
- **`projects`**: Array of projects with workflow file names specific to each branch.## Usage
Run the script using the following command:
```bash
node index.js
```The script will prompt you to select a branch (`develop` or `master`) to run workflows. Based on your selection, it will:
1. Navigate to each project’s GitHub Actions page.
2. Select the specified branch.
3. Start the workflows listed for that branch.### Example Config Prompt
```plaintext
Which branch do you want to run the workflow for (develop/master)?
```## Notes
- Ensure you are logged into GitHub in Chrome/Chromium for Puppeteer to work seamlessly.
- If your account has two-factor authentication, you may need to log in manually during the first run.
- The `userDataDir` path retains login data, reducing the need to re-authenticate.## License
This project is open-source and available under the MIT License.