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

chore(tools): Cache rework for .circleci jobs (part2) #14156

Merged
merged 29 commits into from
Oct 24, 2023
Merged

chore(tools): Cache rework for .circleci jobs (part2) #14156

merged 29 commits into from
Oct 24, 2023

Conversation

zak-pawel
Copy link
Collaborator

@zak-pawel zak-pawel commented Oct 22, 2023

Improvement/fixes

  • For windows:
    • windows-server-2022-gui contains preinstalled go, so we need to be sure that during go upgrade there will not be any clashes or leftovers (like we could observe here) so /c/Program Files/Go will be removed just before restore_cache. These clashes may also appear during go upgrade from previously cached version to newer version.
    • MinGW will also be cached and /c/ProgramData/chocolatey/lib/mingw will be removed just before restore_cache (for the same reason as for go mentioned above). $PATH manipulations were also needed (to check for original gcc inside /c/ProgramData/chocolatey/lib/mingw/tools/install/mingw64/bin and not for shim version in /c/ProgramData/chocolatey/bin) when installing MinGW and running tests with -race.
  • For darwin:
  • For all OSes:
    • Names of cache keys unified to:
      • go-bins-<< parameters.cache_version >>-<< parameters.os >>-<< parameters.arch >>-go<< parameters.goversion >>-{{ checksum "go.sum" }}
      • go-caches-<< parameters.cache_version >>-<< parameters.os >>-<< parameters.arch >>-go<< parameters.goversion >>-{{ checksum "go.sum" }}
    • Printing $PATH, binary (go/gcc) location and version added.

@zak-pawel zak-pawel changed the title Cache go windws chore(tools): Cache go binaries (Windows on CircleCI) Oct 22, 2023
@telegraf-tiger
Copy link
Contributor

@zak-pawel zak-pawel changed the title chore(tools): Cache go binaries (Windows on CircleCI) chore(tools): Cache rework for .circleci jobs (part2) Oct 23, 2023
@zak-pawel zak-pawel marked this pull request as ready for review October 23, 2023 20:20
@zak-pawel zak-pawel requested review from srebhan and powersj October 23, 2023 20:20
Copy link
Contributor

@powersj powersj left a comment

Choose a reason for hiding this comment

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

Thanks for tracking this all down. I have one extra print/echo below, otherwise, happy to see this land soon!

}

export PATH="/c/ProgramData/chocolatey/lib/mingw/tools/install/mingw64/bin:$PATH"
echo "$PATH"
Copy link
Contributor

Choose a reason for hiding this comment

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

This is printed here and below, are both necessary?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

@powersj Just to see what chocolatey added to the $PATH

Copy link
Member

@srebhan srebhan left a comment

Choose a reason for hiding this comment

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

Nice job! Thanks for tackling this issue @zak-pawel!

@srebhan srebhan added the ready for final review This pull request has been reviewed and/or tested by multiple users and is ready for a final review. label Oct 24, 2023
@powersj powersj merged commit 4413991 into influxdata:master Oct 24, 2023
6 checks passed
@github-actions github-actions bot added this to the v1.28.4 milestone Oct 24, 2023
powersj pushed a commit that referenced this pull request Nov 13, 2023
powersj added a commit to powersj/telegraf that referenced this pull request Dec 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
chore ready for final review This pull request has been reviewed and/or tested by multiple users and is ready for a final review.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants