-
Notifications
You must be signed in to change notification settings - Fork 10.5k
Add remote caching option for build.ps1 #80423
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
Add remote caching option for build.ps1 #80423
Conversation
When setting up sccache we can choose between local disk caching or remote caching via an S3-ish blob storage engine. To allow for backward compatibility for anyone that might be using the existing option for disk caching we leave it place and instead provide a new remote caching option. This option assumes you've read the sccache documentation for setting up the correct environment variables for telling sccache where to find the bucket and how to authenticate to it.
cc @compnerd |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd rather not use ParameterSet
here. You can only have a single parameter set, and I would rather that if we were to use it, it would apply to the pinned toolchain parameters.
What is the advantage to having -EnableRemoteCaching
? Why not have a single -EnableCaching
and make the user responsible for configuring the cache?
@compnerd Could certainly do that! @jeffdav and I were talking and thought that maybe people are using |
The expected behavior AFAIK is that |
EnableCaching should only configure cmake to allow for sccache usage, it should not configure sccache itself in any way. Those configuration options should be deferred into the environment variables that sccache will look for when it starts up.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think that this makes sense.
@swift-ci please smoke test |
When setting up sccache we can choose between local disk caching or remote caching via an S3-ish blob storage engine. To allow for backward compatibility for anyone that might be using the existing option for disk caching we leave it place and instead provide a new remote caching option.
This option assumes you've read the sccache documentation for setting up the correct environment variables for telling sccache where to find the bucket and how to authenticate to it.