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

Support get manifest from local #463

Closed
retzero opened this issue Jul 15, 2022 · 5 comments
Closed

Support get manifest from local #463

retzero opened this issue Jul 15, 2022 · 5 comments
Labels
feature request New feature or request to improve the current logic

Comments

@retzero
Copy link

retzero commented Jul 15, 2022

Description:
We ran into a rate limit issue while running our GitHub Enterprise Server instance.
There are several topics discussed below, but they are not suitable for us.
#219, #427, #316

The rate limit problem seems to be caused by importing the manifest file located on github.com.
Wouldn't the problem go away if the action import a local manifest file instead?

I suggest using a local file instead of calling the api to github.com if the hosted runner has a specific environment variable (eg, SETUP_PYTHON_MANIFEST_FILE_LOCATION).

https://github.com/actions/setup-python/blob/main/src/install-python.ts#L19

+ # pseudo code
+ if (SETUP_PYTHON_MANIFEST_FILE_LOCATION is set) {
+   const manifest: tc.IToolRelease[] = getManifestFromLocal(
+   ...
+ } else {
  const manifest: tc.IToolRelease[] = await tc.getManifestFromRepo(

Justification:
Justification or a use case for your proposal.

Are you willing to submit a PR?

@retzero retzero added feature request New feature or request to improve the current logic needs triage labels Jul 15, 2022
@IvanZosimov
Copy link
Contributor

IvanZosimov commented Jul 15, 2022

Hi, @retzero 👋 ! Thank you for this feature request! Unfortunately we aren't planning to implement this feature, but probably I can help you with the issue itself. What is your current rate limit? (check this info about getting your rate limit)

@retzero
Copy link
Author

retzero commented Jul 20, 2022

@IvanZosimov

Thank you for the feedback. I'm looking for a more efficient way to solve the rate limit problem. This is our situation.

  • Our company do not allow enabling GitHub Connect for some reasons.
  • We have tens of thousands of build requests per day.
  • And we're operating 500+ self-hosted runners.
  • There is only one IP exposed to the outside due to the company's NAT configuration.
  • We want to avoid including GitHub.com's PAT in our development source code.
  • Currently, we're using self hosted runners w/ python tool cache set as guided here.
    • Hundreds of developers demand different python versions, so we have to caching tens of GB of full stable versions.
    • It is expensive(time-consuming) to use ephemeral options and/or re-initialize the toolcache where changes occur in every build.

@IvanZosimov
Copy link
Contributor

IvanZosimov commented Jul 21, 2022

Hi, @retzero, thanks for clarifying your case. Unfortunately, I think the best way to solve your problem is to fork action as was suggested here and apply the changes you need.

@brcrista
Copy link
Contributor

brcrista commented Aug 5, 2022

Duplicate of #229

@brcrista brcrista marked this as a duplicate of #229 Aug 5, 2022
@brcrista brcrista closed this as completed Aug 5, 2022
@brcrista
Copy link
Contributor

brcrista commented Aug 5, 2022

We want to avoid including GitHub.com's PAT in our development source code.

Definitely don't put it in your source code. You would store it as a secret in your repo.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request New feature or request to improve the current logic
Projects
None yet
Development

No branches or pull requests

3 participants