Skip to content

Commit

Permalink
chore(.github): unify workflows between master and branch-** (#4152)
Browse files Browse the repository at this point in the history
  • Loading branch information
Michal-Leszczynski authored Dec 11, 2024
1 parent 6f6a5a9 commit bea0205
Show file tree
Hide file tree
Showing 14 changed files with 36 additions and 17 deletions.
3 changes: 2 additions & 1 deletion .github/cfg/integration-test-core.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
on:
push:
branches:
- branch-3.4
- master
- 'branch-**'
pull_request:
types: [ opened, synchronize, reopened ]

Expand Down
13 changes: 10 additions & 3 deletions .github/cfg/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@ func (cfg integrationTestCfg) scyllaVersion() string {
// This is a simple script used to generate workflow files by applying
// each config from './integration-test-cfg.yaml' onto './integration-test-core.yaml'.
// It also prints github badges syntax that can be pasted into the README.md file.
// It has to be run from the same dir with 'go run main.go' command.
// It has to be run from the same dir with 'go run main.go <badge-branch>' command.
// The <badge-branch> ('master' by default) arg specifies the branch from which the badges are generated.
func main() {
f, err := os.ReadFile("./integration-test-cfg.yaml")
if err != nil {
Expand Down Expand Up @@ -74,6 +75,12 @@ func main() {
}
}

// Select badge branch
branch := "master"
if len(os.Args) == 2 {
branch = os.Args[1]
}

fmt.Println("Reference links to badges")
versionBadges := make(map[string][]string)
for _, cfg := range configs {
Expand All @@ -90,8 +97,8 @@ func main() {
}

versionBadges[v] = append(versionBadges[v], "!["+name+"]")
fmt.Printf("[%s]: https://github.com/scylladb/scylla-manager/actions/workflows/%s.yaml/badge.svg?branch=master\n",
name, name)
fmt.Printf("[%s]: https://github.com/scylladb/scylla-manager/actions/workflows/%s.yaml/badge.svg?branch=%s\n",
name, name, branch)
}

fmt.Println("Badges formatted as table")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -108,4 +108,5 @@ name: integration-tests-2023.1.11-IPV4-raftschema
- reopened
push:
branches:
- branch-3.4
- master
- branch-**
3 changes: 2 additions & 1 deletion .github/workflows/integration-tests-2023.1.11-IPV4.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -108,4 +108,5 @@ name: integration-tests-2023.1.11-IPV4
- reopened
push:
branches:
- branch-3.4
- master
- branch-**
Original file line number Diff line number Diff line change
Expand Up @@ -108,4 +108,5 @@ name: integration-tests-2023.1.11-IPV6-raftschema
- reopened
push:
branches:
- branch-3.4
- master
- branch-**
3 changes: 2 additions & 1 deletion .github/workflows/integration-tests-2024.1.9-IPV4.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -108,4 +108,5 @@ name: integration-tests-2024.1.9-IPV4
- reopened
push:
branches:
- branch-3.4
- master
- branch-**
3 changes: 2 additions & 1 deletion .github/workflows/integration-tests-2024.1.9-IPV6.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -108,4 +108,5 @@ name: integration-tests-2024.1.9-IPV6
- reopened
push:
branches:
- branch-3.4
- master
- branch-**
3 changes: 2 additions & 1 deletion .github/workflows/integration-tests-6.1.1-IPV4-tablets.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -108,4 +108,5 @@ name: integration-tests-6.1.1-IPV4-tablets
- reopened
push:
branches:
- branch-3.4
- master
- branch-**
3 changes: 2 additions & 1 deletion .github/workflows/integration-tests-6.1.1-IPV4.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -108,4 +108,5 @@ name: integration-tests-6.1.1-IPV4
- reopened
push:
branches:
- branch-3.4
- master
- branch-**
3 changes: 2 additions & 1 deletion .github/workflows/integration-tests-6.1.1-IPV6-tablets.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -108,4 +108,5 @@ name: integration-tests-6.1.1-IPV6-tablets
- reopened
push:
branches:
- branch-3.4
- master
- branch-**
Original file line number Diff line number Diff line change
Expand Up @@ -108,4 +108,5 @@ name: integration-tests-latest-enterprise-IPV4-tablets
- reopened
push:
branches:
- branch-3.4
- master
- branch-**
Original file line number Diff line number Diff line change
Expand Up @@ -108,4 +108,5 @@ name: integration-tests-latest-enterprise-IPV4
- reopened
push:
branches:
- branch-3.4
- master
- branch-**
3 changes: 2 additions & 1 deletion .github/workflows/sanity-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ name: Sanity check
on:
push:
branches:
- branch-3.4
- master
- 'branch-**'
pull_request:
types: [ opened, synchronize, reopened ]

Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ Scylla Manager consists of tree components:
| **6.1.1** | ![integration-tests-6.1.1-IPV4]<br/>![integration-tests-6.1.1-IPV4-tablets]<br/>![integration-tests-6.1.1-IPV6-tablets] | Restoration of **Authentication** and **Service Levels** is not supported<br/>Restoration of schema containing **Alternator** tables is not supported |
| **latest-enterprise** | ![integration-tests-latest-enterprise-IPV4]<br/>![integration-tests-latest-enterprise-IPV4-tablets] | Restoration of **Authentication** and **Service Levels** is not supported<br/>Restoration of schema containing **Alternator** tables is not supported |

[integration-tests-2024.1.9-IPV4]: https://github.com/scylladb/scylla-manager/actions/workflows/integration-tests-2024.1.9-IPV4.yaml/badge.svg?branch=branch-3.4
[integration-tests-2024.1.9-IPV6]: https://github.com/scylladb/scylla-manager/actions/workflows/integration-tests-2024.1.9-IPV6.yaml/badge.svg?branch=branch-3.4
[integration-tests-2023.1.11-IPV4]: https://github.com/scylladb/scylla-manager/actions/workflows/integration-tests-2023.1.11-IPV4.yaml/badge.svg?branch=branch-3.4
[integration-tests-2023.1.11-IPV4-raftschema]: https://github.com/scylladb/scylla-manager/actions/workflows/integration-tests-2023.1.11-IPV4-raftschema.yaml/badge.svg?branch=branch-3.4
[integration-tests-2023.1.11-IPV6-raftschema]: https://github.com/scylladb/scylla-manager/actions/workflows/integration-tests-2023.1.11-IPV6-raftschema.yaml/badge.svg?branch=branch-3.4
[integration-tests-2024.1.9-IPV4]: https://github.com/scylladb/scylla-manager/actions/workflows/integration-tests-2024.1.9-IPV4.yaml/badge.svg?branch=branch-3.4
[integration-tests-2024.1.9-IPV6]: https://github.com/scylladb/scylla-manager/actions/workflows/integration-tests-2024.1.9-IPV6.yaml/badge.svg?branch=branch-3.4
[integration-tests-6.1.1-IPV4]: https://github.com/scylladb/scylla-manager/actions/workflows/integration-tests-6.1.1-IPV4.yaml/badge.svg?branch=branch-3.4
[integration-tests-6.1.1-IPV4-tablets]: https://github.com/scylladb/scylla-manager/actions/workflows/integration-tests-6.1.1-IPV4-tablets.yaml/badge.svg?branch=branch-3.4
[integration-tests-6.1.1-IPV6-tablets]: https://github.com/scylladb/scylla-manager/actions/workflows/integration-tests-6.1.1-IPV6-tablets.yaml/badge.svg?branch=branch-3.4
Expand Down

0 comments on commit bea0205

Please sign in to comment.