Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 60a047b675 |
@@ -17,6 +17,7 @@ export const createAttestation = async (
|
|||||||
sigstoreInstance: SigstoreInstance
|
sigstoreInstance: SigstoreInstance
|
||||||
pushToRegistry: boolean
|
pushToRegistry: boolean
|
||||||
githubToken: string
|
githubToken: string
|
||||||
|
ociCompatMode: boolean
|
||||||
}
|
}
|
||||||
): Promise<AttestResult> => {
|
): Promise<AttestResult> => {
|
||||||
// Sign provenance w/ Sigstore
|
// Sign provenance w/ Sigstore
|
||||||
@@ -43,6 +44,7 @@ export const createAttestation = async (
|
|||||||
'dev.sigstore.bundle.content': 'dsse-envelope',
|
'dev.sigstore.bundle.content': 'dsse-envelope',
|
||||||
'dev.sigstore.bundle.predicateType': predicate.type
|
'dev.sigstore.bundle.predicateType': predicate.type
|
||||||
},
|
},
|
||||||
|
compatibility: opts.ociCompatMode,
|
||||||
fetchOpts: { timeout: OCI_TIMEOUT, retry: OCI_RETRY }
|
fetchOpts: { timeout: OCI_TIMEOUT, retry: OCI_RETRY }
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|||||||
@@ -18,6 +18,9 @@ const inputs: RunInputs = {
|
|||||||
// undocumented -- not part of public interface
|
// undocumented -- not part of public interface
|
||||||
privateSigning: ['true', 'True', 'TRUE', '1'].includes(
|
privateSigning: ['true', 'True', 'TRUE', '1'].includes(
|
||||||
core.getInput('private-signing')
|
core.getInput('private-signing')
|
||||||
|
),
|
||||||
|
ociCompatMode: ['true', 'True', 'TRUE', '1'].includes(
|
||||||
|
core.getInput('oci-compatibility-mode')
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+3
-1
@@ -23,6 +23,7 @@ export type RunInputs = SubjectInputs &
|
|||||||
githubToken: string
|
githubToken: string
|
||||||
showSummary: boolean
|
showSummary: boolean
|
||||||
privateSigning: boolean
|
privateSigning: boolean
|
||||||
|
ociCompatMode: boolean
|
||||||
}
|
}
|
||||||
|
|
||||||
/* istanbul ignore next */
|
/* istanbul ignore next */
|
||||||
@@ -68,7 +69,8 @@ export async function run(inputs: RunInputs): Promise<void> {
|
|||||||
const att = await createAttestation(subjects, predicate, {
|
const att = await createAttestation(subjects, predicate, {
|
||||||
sigstoreInstance,
|
sigstoreInstance,
|
||||||
pushToRegistry: inputs.pushToRegistry,
|
pushToRegistry: inputs.pushToRegistry,
|
||||||
githubToken: inputs.githubToken
|
githubToken: inputs.githubToken,
|
||||||
|
ociCompatMode: inputs.ociCompatMode
|
||||||
})
|
})
|
||||||
|
|
||||||
logAttestation(subjects, att, sigstoreInstance)
|
logAttestation(subjects, att, sigstoreInstance)
|
||||||
|
|||||||
Reference in New Issue
Block a user