mirror of
https://github.com/actions/cache.git
synced 2025-04-21 19:46:46 +00:00
Initial pass at chunked upload apis
This commit is contained in:
parent
4809f4ada4
commit
bad827c28e
6 changed files with 158 additions and 50 deletions
|
@ -65,14 +65,14 @@ async function run(): Promise<void> {
|
|||
core.debug(`Tar Path: ${tarPath}`);
|
||||
await exec(`"${tarPath}"`, args);
|
||||
|
||||
const fileSizeLimit = 400 * 1024 * 1024; // 400MB
|
||||
const fileSizeLimit = 2 * 1024 * 1024 * 1024; // 2GB per repo limit
|
||||
const archiveFileSize = utils.getArchiveFileSize(archivePath);
|
||||
core.debug(`File Size: ${archiveFileSize}`);
|
||||
if (archiveFileSize > fileSizeLimit) {
|
||||
utils.logWarning(
|
||||
`Cache size of ~${Math.round(
|
||||
archiveFileSize / (1024 * 1024)
|
||||
)} MB (${archiveFileSize} B) is over the 400MB limit, not saving cache.`
|
||||
archiveFileSize / (1024 * 1024 * 1024)
|
||||
)} GB (${archiveFileSize} B) is over the 2GB limit, not saving cache.`
|
||||
);
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue