-
Notifications
You must be signed in to change notification settings - Fork 6
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
solve disk usage #79
solve disk usage #79
Conversation
50ec208
to
d4f392a
Compare
If using Yarn 3.7.0 works, then I may need to explicitly enableGlobalCache If it doesn't I may have to try harder to |
d049be6
to
968cad4
Compare
968cad4
to
e8fce15
Compare
|
||
- run: docker system df | ||
- run: docker buildx du --verbose | ||
- run: df -h |
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.
these blocks aren't necessary for main, but I'd like to leave it in this PR.
- to not delay merge by another run (taking over an hour)
- to have the diagnostics a little longer while the change settles
If #2 is not compelling, I'm open to cutting e8fce15 from this branch and merging without another green.
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.
diagnostics of this sort are somewhere between cost-effective and priceless, IME. (unless they're very, very verbose; I haven't checked in this case).
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.
yeah; something has got to be done about this
This looks like it can't hurt much.
|
||
- run: docker system df | ||
- run: docker buildx du --verbose | ||
- run: df -h |
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.
diagnostics of this sort are somewhere between cost-effective and priceless, IME. (unless they're very, very verbose; I haven't checked in this case).
@@ -64,13 +64,16 @@ export const buildProposalSubmissions = (proposals: ProposalInfo[]) => { | |||
|
|||
/** | |||
* Bake images using the docker buildx bake command. |
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'm not familiar with docker buildx bake
. But I gather it's working...
const yarnRc = path.join(proposalPath, '.yarnrc.yml'); | ||
if (!fs.existsSync(yarnRc)) { | ||
console.log(`creating ${yarnRc} with node-modules linker`); | ||
fs.writeFileSync(yarnRc, 'nodeLinker: node-modules\n'); | ||
} | ||
|
||
// refresh install | ||
execSync('rm -rf node_modules', { cwd: proposalPath }); |
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.
🤔
// delete the image to reclaim disk space. The next build | ||
// will use the build cache. | ||
execSync('docker system df', { stdio: 'inherit' }); | ||
execSync(`docker rmi ${image.name}`, { stdio: 'inherit' }); |
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 gather this docker rmi ...
is the gist of it.
const cmd = `docker run --rm ${name}`; | ||
execSync(cmd, { stdio: 'inherit' }); | ||
} | ||
export const runTestImage = (proposal: ProposalInfo) => { |
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.
the API change from runTestImages
to runTestImage
sets off my backward-compatibility sensor.
But I don't suppose that's all that relevant in this context.
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.
the CLI's modules aren't part of the package API.
The package doesn't yet define "exports"
so they technically could be imported somewhere, but I think it's a reasonable expectation that cli
not be.
That said, this package doesn't claim backwards compatibility because, following semver, it's not yet 1.0.
closes: #78
CI time 62m vs 66m before the "use" PR. (no statsig diff)