github.com/apptainer/singularity@v3.1.1+incompatible/pkg/build/types/remote.go (about)

     1  // Copyright (c) 2018, Sylabs Inc. All rights reserved.
     2  // This software is licensed under a 3-clause BSD license. Please consult the
     3  // LICENSE.md file distributed with the sources of this project regarding your
     4  // rights to use or distribute this software.
     5  
     6  package types
     7  
     8  import (
     9  	"time"
    10  
    11  	"github.com/globalsign/mgo/bson"
    12  )
    13  
    14  // RequestData contains the info necessary for submitting a build to a remote service
    15  type RequestData struct {
    16  	Definition  `json:"definition"`
    17  	LibraryRef  string `json:"libraryRef"`
    18  	LibraryURL  string `json:"libraryURL"`
    19  	CallbackURL string `json:"callbackURL"`
    20  }
    21  
    22  // ResponseData contains the details of an individual build
    23  type ResponseData struct {
    24  	ID            bson.ObjectId `json:"id"`
    25  	CreatedBy     string        `json:"createdBy"`
    26  	SubmitTime    time.Time     `json:"submitTime"`
    27  	StartTime     *time.Time    `json:"startTime,omitempty" bson:",omitempty"`
    28  	IsComplete    bool          `json:"isComplete"`
    29  	CompleteTime  *time.Time    `json:"completeTime,omitempty"`
    30  	ImageSize     int64         `json:"imageSize,omitempty"`
    31  	ImageChecksum string        `json:"imageChecksum,omitempty"`
    32  	Definition    Definition    `json:"definition"`
    33  	WSURL         string        `json:"wsURL,omitempty" bson:"-"`
    34  	LibraryRef    string        `json:"libraryRef"`
    35  	LibraryURL    string        `json:"libraryURL"`
    36  	CallbackURL   string        `json:"callbackURL"`
    37  }