Skip to content

Commit

Permalink
wip: dsse type
Browse files Browse the repository at this point in the history
  • Loading branch information
mikhailswift committed Jan 13, 2022
1 parent 0e9631f commit c7d0209
Show file tree
Hide file tree
Showing 13 changed files with 1,273 additions and 8 deletions.
1 change: 1 addition & 0 deletions cmd/rekor-cli/app/root.go
Expand Up @@ -30,6 +30,7 @@ import (

// these imports are to call the packages' init methods
_ "github.com/sigstore/rekor/pkg/types/alpine/v0.0.1"
_ "github.com/sigstore/rekor/pkg/types/dsse/v0.0.1"
_ "github.com/sigstore/rekor/pkg/types/hashedrekord/v0.0.1"
_ "github.com/sigstore/rekor/pkg/types/helm/v0.0.1"
_ "github.com/sigstore/rekor/pkg/types/intoto/v0.0.1"
Expand Down
3 changes: 3 additions & 0 deletions cmd/rekor-server/app/serve.go
Expand Up @@ -30,6 +30,8 @@ import (
"github.com/sigstore/rekor/pkg/log"
"github.com/sigstore/rekor/pkg/types/alpine"
alpine_v001 "github.com/sigstore/rekor/pkg/types/alpine/v0.0.1"
"github.com/sigstore/rekor/pkg/types/dsse"
dsse_v001 "github.com/sigstore/rekor/pkg/types/dsse/v0.0.1"
hashedrekord "github.com/sigstore/rekor/pkg/types/hashedrekord"
hashedrekord_v001 "github.com/sigstore/rekor/pkg/types/hashedrekord/v0.0.1"
"github.com/sigstore/rekor/pkg/types/helm"
Expand Down Expand Up @@ -91,6 +93,7 @@ var serveCmd = &cobra.Command{
helm.KIND: helm_v001.APIVERSION,
tuf.KIND: tuf_v001.APIVERSION,
hashedrekord.KIND: hashedrekord_v001.APIVERSION,
dsse.KIND: dsse_v001.APIVERSION,
}

for k, v := range pluggableTypeMap {
Expand Down
17 changes: 17 additions & 0 deletions openapi.yaml
Expand Up @@ -444,6 +444,23 @@ definitions:
- spec
additionalProperties: false

dsse:
type: object
description: DSSE object
allOf:
- $ref: '#/definitions/ProposedEntry'
- properties:
apiVersion:
type: string
pattern: ^(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?$
spec:
type: object
$ref: 'pkg/types/dsse/dsse_schema.json'
required:
- apiVersion
- spec
additionalProperties: false

rfc3161:
type: object
description: RFC3161 Timestamp
Expand Down
210 changes: 210 additions & 0 deletions pkg/generated/models/dsse.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

29 changes: 29 additions & 0 deletions pkg/generated/models/dsse_schema.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit c7d0209

Please sign in to comment.