Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Do not use gh-hosted-runners-16cores-1 runners on forks #17237

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

arthurschreiber
Copy link
Contributor

@arthurschreiber arthurschreiber commented Nov 15, 2024

Description

We (GitHub) and other members of the community maintain our own Vitess fork. We rely on the CI builds to ensure that when we backport changes into our fork, we don't introduce any bugs or other issues.

We only have access to the "normal" runner types, and don't have access to gh-hosted-runners-16cores-1, which is specific to the vitessio organization and I guess is provided by CNCF.

By checking whether a workflow runs in the scope of the vitessio organization, and then deciding between gh-hosted-runners-16cores-1 or the regular ubuntu-latest runners, we can allow workflows to run in forks of the vitess repo as well.

cc @timvaillancourt as you might be interested in this as well.

I'd like to see this backported in all supported branches, as this will make my live considerably easier without having any real impact on the upstream Vitess repository. 😅

Related Issue(s)

N/A

Checklist

  • "Backport to:" labels have been added if this change should be back-ported to release branches
  • If this change is to be back-ported to previous releases, a justification is included in the PR description
  • Tests were added or are not required
  • Did the new or modified tests pass consistently locally and on CI?
  • Documentation was added or is not required

Deployment Notes

…low is running in the `vitessio/vitess` repository.

Signed-off-by: Arthur Schreiber <[email protected]>
Copy link
Contributor

vitess-bot bot commented Nov 15, 2024

Review Checklist

Hello reviewers! 👋 Please follow this checklist when reviewing this Pull Request.

General

  • Ensure that the Pull Request has a descriptive title.
  • Ensure there is a link to an issue (except for internal cleanup and flaky test fixes), new features should have an RFC that documents use cases and test cases.

Tests

  • Bug fixes should have at least one unit or end-to-end test, enhancement and new features should have a sufficient number of tests.

Documentation

  • Apply the release notes (needs details) label if users need to know about this change.
  • New features should be documented.
  • There should be some code comments as to why things are implemented the way they are.
  • There should be a comment at the top of each new or modified test to explain what the test does.

New flags

  • Is this flag really necessary?
  • Flag names must be clear and intuitive, use dashes (-), and have a clear help text.

If a workflow is added or modified:

  • Each item in Jobs should be named in order to mark it as required.
  • If the workflow needs to be marked as required, the maintainer team must be notified.

Backward compatibility

  • Protobuf changes should be wire-compatible.
  • Changes to _vt tables and RPCs need to be backward compatible.
  • RPC changes should be compatible with vitess-operator
  • If a flag is removed, then it should also be removed from vitess-operator and arewefastyet, if used there.
  • vtctl command output order should be stable and awk-able.

@vitess-bot vitess-bot bot added NeedsBackportReason If backport labels have been applied to a PR, a justification is required NeedsDescriptionUpdate The description is not clear or comprehensive enough, and needs work NeedsIssue A linked issue is missing for this Pull Request NeedsWebsiteDocsUpdate What it says labels Nov 15, 2024
@github-actions github-actions bot added this to the v22.0.0 milestone Nov 15, 2024
@arthurschreiber arthurschreiber added Backport to: release-19.0 Needs to be back ported to release-19.0 Backport to: release-20.0 Needs to be backport to release-20.0 Backport to: release-21.0 Needs to be backport to release-21.0 Component: Build/CI Type: Enhancement Logical improvement (somewhere between a bug and feature) and removed NeedsDescriptionUpdate The description is not clear or comprehensive enough, and needs work NeedsWebsiteDocsUpdate What it says NeedsIssue A linked issue is missing for this Pull Request NeedsBackportReason If backport labels have been applied to a PR, a justification is required labels Nov 15, 2024
Copy link

codecov bot commented Nov 15, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 67.40%. Comparing base (3499a77) to head (4110979).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #17237      +/-   ##
==========================================
+ Coverage   67.39%   67.40%   +0.01%     
==========================================
  Files        1570     1570              
  Lines      252903   252912       +9     
==========================================
+ Hits       170451   170485      +34     
+ Misses      82452    82427      -25     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@@ -16,7 +16,7 @@ env:
jobs:
build:
name: Run endtoend tests on Cluster (onlineddl_vrepl)
runs-on: gh-hosted-runners-16cores-1
runs-on: ${{ github.repository_owner == 'vitessio' && 'gh-hosted-runners-16cores-1' || 'ubuntu-latest' }}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I thunk we should pin a to a specific known working ubuntu version and not latest. That we do that in other jobs in a mistake imho, we explicitly pinned it in the past to avoid having to scramble when it gets updated.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm okay with that, but I think that should probably go into a separate PR, right? 🤔

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agree with @dbussink on this. we should not be overriding the vitessio org runner with ubuntu-latest, it should be pinned to the actual latest version.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the heads up. Will upgrade this tomorrow

Copy link
Member

@frouioui frouioui left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to me @arthurschreiber.

@timvaillancourt
Copy link
Contributor

cc @timvaillancourt as you might be interested in this as well.

@arthurschreiber thanks, I was thinking of adding the same - we have to patch this manually, as I suspect you're doing

This gave me an idea, would it make things easier for the upstream repo if gh-hosted-runners-16cores-1 was a GitHub action variable/secret? Or if this selection was triggered by the existence of it? 🤔

@arthurschreiber
Copy link
Contributor Author

This gave me an idea, would it make things easier for the upstream repo if gh-hosted-runners-16cores-1 was a GitHub action variable/secret? Or if this selection was triggered by the existence of it? 🤔

Not sure if that makes it easier. I doubt the value of this changes often, and putting it into a variable / secret just adds another step? But @frouioui and others might have a different opinion.

@frouioui
Copy link
Member

@timvaillancourt, I agree with @arthurschreiber, I feel like having an environment variable would make it more complicated as new forks will have to figure out they need to set one. We could have a default value, but if we change it upstream, forks using the environment variable will have to be up-to-date with what the recommended OS is.

@timvaillancourt
Copy link
Contributor

timvaillancourt commented Nov 20, 2024

We'll be fine continuing to patch, but on our fork we use neither gh-hosted-runners-16cores-1 or ubuntu-latest as the runner name/group

EDIT/context: we run a paid GitHub Actions runner that made our CI much more stable (vs free public tier)

@deepthi
Copy link
Member

deepthi commented Nov 25, 2024

@arthurschreiber you might need to fix this up because of #17278

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Backport to: release-19.0 Needs to be back ported to release-19.0 Backport to: release-20.0 Needs to be backport to release-20.0 Backport to: release-21.0 Needs to be backport to release-21.0 Component: Build/CI Type: Enhancement Logical improvement (somewhere between a bug and feature)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants