Skip to content

Commit e2e5165

Browse files
committed
feat: add cluster pin expiry
1 parent b1c89c9 commit e2e5165

File tree

3 files changed

+14
-0
lines changed

3 files changed

+14
-0
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## Unreleased
99

10+
## [1.4.0] - 2025-03-05
11+
12+
### Added
13+
14+
- Add support for time-bound pins in IPFS Cluster via the `cluster-pin-expire-in` input parameter.
15+
1016
## [1.3.0] - 2025-03-05
1117

1218
### Added

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,7 @@ The signing key and proof will be used as [inputs](#inputs) to the action.
8383
| `upload-car-artifact` | Upload and publish the CAR file on GitHub Action Summary pages | `'true'` |
8484
| `cluster-retry-attempts` | Number of retry attempts for IPFS Cluster uploads | `'5'` |
8585
| `cluster-timeout-minutes` | Timeout in minutes for each IPFS Cluster upload attempt | `'2'` |
86+
| `cluster-pin-expire-in` | Time duration after which the pin will expire in IPFS Cluster (e.g. 720h for 30 days) | - |
8687

8788
## Outputs
8889

action.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,9 @@ inputs:
4343
description: 'IPFS Cluster CLI version to use'
4444
default: 'v1.1.2'
4545
required: false
46+
cluster-pin-expire-in:
47+
description: 'Time duration after which the pin will expire in IPFS Cluster (e.g. 720h for 30 days). Only supported by IPFS Cluster.'
48+
required: false
4649
storacha-key:
4750
description: 'Storacha base64 encoded key to use to sign UCAN invocations. Create one using `w3 key create --json`. See: https://github.com/storacha/w3cli#w3_principal'
4851
required: false
@@ -240,8 +243,12 @@ runs:
240243
add --format=car \
241244
--local \
242245
--name "${{ github.repository }}/${{ github.sha }}" \
246+
${{ inputs.cluster-pin-expire-in != '' && format('--expire-in {0}', inputs.cluster-pin-expire-in) || '' }} \
243247
build.car && {
244248
echo "✅ Uploaded CAR with CID ${{ steps.merkleize.outputs.cid }} to IPFS Cluster" >> $GITHUB_STEP_SUMMARY
249+
if [[ -n "${{ inputs.cluster-pin-expire-in }}" ]]; then
250+
echo "⏰ IPFS Cluster Pin is set to expire in ${{ inputs.cluster-pin-expire-in }}" >> $GITHUB_STEP_SUMMARY
251+
fi
245252
exit 0
246253
}
247254

0 commit comments

Comments
 (0)