Path: blob/main/components/content-service-api/go/content-manifest.go
2500 views
// Copyright (c) 2020 Gitpod GmbH. All rights reserved.1// Licensed under the GNU Affero General Public License (AGPL).2// See License.AGPL.txt in the project root for license information.34package api56import (7digest "github.com/opencontainers/go-digest"8ociv1 "github.com/opencontainers/image-spec/specs-go/v1"9)1011const (12// ContentTypeManifest manifest is the content type for a JSON serialized WorkspaceContentManifest13ContentTypeManifest = "application/vnd.gitpod.ws.manifest.v1+json"1415// MediaTypeUncompressedLayer is a valid OCIv1 media type for uncompressed layer archives16MediaTypeUncompressedLayer = ociv1.MediaTypeImageLayer17)1819// WorkspaceContentManifest describes the content that makes up a workspace20type WorkspaceContentManifest struct {21Layers []WorkspaceContentLayer `json:"layers"`22}2324// WorkspaceContentLayer describes the disposition of a single content layer.25type WorkspaceContentLayer struct {26ociv1.Descriptor2728// Bucket where to find the actual layer file.29Bucket string `json:"bucket"`30// Object naem of the actual layer file in the bucket.31Object string `json:"object"`32// DiffID is the digest of the uncompressed targeted content.33DiffID digest.Digest `json:"diffID"`3435// Workspace instance ID this content layer came from36InstanceID string `json:"instanceID"`37}383940