Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/kamu-data/reusable-workflows
https://github.com/kamu-data/reusable-workflows
Last synced: 3 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/kamu-data/reusable-workflows
- Owner: kamu-data
- Created: 2024-02-27T21:12:26.000Z (9 months ago)
- Default Branch: master
- Last Pushed: 2024-04-12T22:27:57.000Z (7 months ago)
- Last Synced: 2024-04-13T08:02:14.293Z (7 months ago)
- Size: 13.7 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Reusable workflows for GitHub Actions
This repository contains workflows reused across different Kamu
repositories to automate operations with GitHub Actions.## helmfile-workflow.yml
Runs specified helmfile action on a Kubernetes cluster.
### Inputs
| Variable | Type | Required | Default |
|------------------|--------|----------|----------|
| aws_region | string | true | |
| cluster_name | string | true | |
| environment | string | true | |
| helm_action | string | true | |
| iam_role_arn | string | true | |
| helm_version | string | false | v3.13.1 |
| helmfile_version | string | false | v0.158.0 |
| sops_version | string | false | 3.8.1 |### Outputs
None
### Example
```yaml
jobs:
verify:
uses: kamu-data/reusable-workflows/.github/workflows/helmfile-workflow.yml@master
with:
aws_region: us-east-1
cluster_name: my-cluster
environment: my-helmfile-environment
helm_action: diff
iam_role_arn: arn:aws:::0000000::my-role
```## reusable-strategy.yml
Allows to specify a GitHub Actions strategy in a JSON-formatted text
file and re-use it in multiple jobs.### Inputs
| Variable | Type | Required | Default |
|---------------|--------|----------|---------------------------------|
| strategy_file | string | false | .github/workflows/strategy.json |### Outputs
| Variable | Type | Description |
|----------|--------|-------------------------|
| strategy | string | JSON-formatted strategy |### Example
Put the following JSON object to `.github/workflows/strategy.json`:
```json
{
"fail-fast": false,
"matrix": {
"my_variable": [
"foo",
"bar"
]
}
}```
The workflow file will look as follows:
```yaml
jobs:
strategy:
uses: kamu-data/reusable-workflows/.github/workflows/reusable-strategy.yml@master
verify:
needs: [ strategy ]
strategy: ${{ fromJson(needs.strategy.outputs.strategy) }}
run: echo ${{ matrix.my_variable }}
```