Skip to content

Commit 0bc27c2

Browse files
committed
Pass options properly.
1 parent cb0a273 commit 0bc27c2

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/index.ts

+6-1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ import * as path from 'path';
99
import { calculateCacheConfigs, calculateCacheVersion, getSetupActions, getWorkflows } from './cache_predictor';
1010
import { getCacheDirectories, getPackageManagerInfo } from './cache_predictor/node';
1111
import { FinalizeCacheEntryUploadRequest, FinalizeCacheEntryUploadResponse, CreateCacheEntryRequest } from '@actions/cache/lib/generated/results/api/v1/cache';
12+
import { UploadOptions } from '@actions/cache/lib/options';
1213

1314
var cacheTwirpClient = require('@actions/cache/lib/internal/shared/cacheTwirpClient');
1415
var cacheHttpClient = require('@actions/cache/lib/internal/cacheHttpClient');
@@ -55,8 +56,12 @@ async function setEntry(archive: string, key: string, version: string, runtimeTo
5556

5657
const response = await twirpClient.CreateCacheEntry(request);
5758

59+
const options: UploadOptions = {
60+
useAzureSdk: true
61+
}
62+
5863
if (response.ok) {
59-
await cacheHttpClient.saveCache(-1, archive, response.signedUploadUrl);
64+
await cacheHttpClient.saveCache(-1, archive, response.signedUploadUrl, options);
6065
console.log('Cache entry created successfully:', response.data);
6166

6267
const finalizeRequest: FinalizeCacheEntryUploadRequest = {

0 commit comments

Comments
 (0)