Documentation ¶
Index ¶
- Variables
- type Blob
- type BlobSorting
- type BlobsDir
- type BlobsDirReporter
- type Config
- type DigestBlobstore
- type ErrBlobstore
- type FSBlobsDir
- type FSConfig
- type FSGenerator
- type FSGitRepo
- type FSReleaseDir
- func (d FSReleaseDir) BuildRelease(name string, version semver.Version, force bool) (boshrel.Release, error)
- func (d FSReleaseDir) DefaultName() (string, error)
- func (d FSReleaseDir) FinalizeRelease(release boshrel.Release, force bool) error
- func (d FSReleaseDir) FindRelease(name string, version semver.Version) (boshrel.Release, error)
- func (d FSReleaseDir) GenerateJob(name string) error
- func (d FSReleaseDir) GeneratePackage(name string) error
- func (d FSReleaseDir) Init(git bool) error
- func (d FSReleaseDir) NextDevVersion(name string, timestamp bool) (semver.Version, error)
- func (d FSReleaseDir) NextFinalVersion(name string) (semver.Version, error)
- func (d FSReleaseDir) Reset() error
- func (d FSReleaseDir) VendorPackage(pkg *boshpkg.Package) error
- type FSReleaseIndex
- type GCSBlobstore
- type Generator
- type GitRepo
- type Provider
- type ReleaseDir
- type ReleaseIndex
- type ReleaseIndexReporter
- type S3Blobstore
Constants ¶
This section is empty.
Variables ¶
View Source
var ( DefaultFinalVersion = semver.MustNewVersionFromString("1") DefaultDevVersion = semver.MustNewVersionFromString("0+dev.0") DefaultDevPostRelease = semver.MustNewVersionSegmentFromString("dev.1") )
Functions ¶
This section is empty.
Types ¶
type BlobSorting ¶
type BlobSorting []Blob
func (BlobSorting) Len ¶
func (s BlobSorting) Len() int
func (BlobSorting) Less ¶
func (s BlobSorting) Less(i, j int) bool
func (BlobSorting) Swap ¶
func (s BlobSorting) Swap(i, j int)
type BlobsDirReporter ¶
type DigestBlobstore ¶
type DigestBlobstore interface { Get(blobID string, digest boshcrypto.Digest) (fileName string, err error) CleanUp(fileName string) (err error) Create(fileName string) (blobID string, digest boshcrypto.MultipleDigest, err error) Validate() (err error) Delete(blobId string) (err error) }
type ErrBlobstore ¶
type ErrBlobstore struct {
// contains filtered or unexported fields
}
ErrBlobstore postpones returning an error until one of the actions are performed.
func NewErrBlobstore ¶
func NewErrBlobstore(err error) ErrBlobstore
func (ErrBlobstore) CleanUp ¶
func (b ErrBlobstore) CleanUp(path string) error
func (ErrBlobstore) Create ¶
func (b ErrBlobstore) Create(path string) (string, crypto.MultipleDigest, error)
func (ErrBlobstore) Delete ¶
func (b ErrBlobstore) Delete(blobID string) error
func (ErrBlobstore) Validate ¶
func (b ErrBlobstore) Validate() error
type FSBlobsDir ¶
type FSBlobsDir struct {
// contains filtered or unexported fields
}
func NewFSBlobsDir ¶
func NewFSBlobsDir( dirPath string, reporter BlobsDirReporter, blobstore boshblob.DigestBlobstore, digestCalculator bicrypto.DigestCalculator, fs boshsys.FileSystem, logger boshlog.Logger, ) FSBlobsDir
func (FSBlobsDir) Blobs ¶
func (d FSBlobsDir) Blobs() ([]Blob, error)
func (FSBlobsDir) Init ¶
func (d FSBlobsDir) Init() error
func (FSBlobsDir) SyncBlobs ¶
func (d FSBlobsDir) SyncBlobs(parallel int) error
func (FSBlobsDir) TrackBlob ¶
func (d FSBlobsDir) TrackBlob(path string, src io.ReadCloser) (Blob, error)
func (FSBlobsDir) UntrackBlob ¶
func (d FSBlobsDir) UntrackBlob(path string) error
func (FSBlobsDir) UploadBlobs ¶
func (d FSBlobsDir) UploadBlobs() error
type FSConfig ¶
type FSConfig struct {
// contains filtered or unexported fields
}
func NewFSConfig ¶
func NewFSConfig(publicPath, privatePath string, fs boshsys.FileSystem) FSConfig
type FSGenerator ¶
type FSGenerator struct {
// contains filtered or unexported fields
}
func NewFSGenerator ¶
func NewFSGenerator(dirPath string, fs boshsys.FileSystem) FSGenerator
func (FSGenerator) GenerateJob ¶
func (g FSGenerator) GenerateJob(name string) error
func (FSGenerator) GeneratePackage ¶
func (g FSGenerator) GeneratePackage(name string) error
type FSGitRepo ¶
type FSGitRepo struct {
// contains filtered or unexported fields
}
func NewFSGitRepo ¶
func (FSGitRepo) LastCommitSHA ¶
type FSReleaseDir ¶
type FSReleaseDir struct {
// contains filtered or unexported fields
}
func NewFSReleaseDir ¶
func NewFSReleaseDir( dirPath string, config Config, gitRepo GitRepo, blobsDir BlobsDir, generator Generator, devReleases ReleaseIndex, finalReleases ReleaseIndex, finalIndicies boshrel.ArchiveIndicies, releaseReader boshrel.Reader, timeService clock.Clock, fs boshsys.FileSystem, parallel int, ) FSReleaseDir
func (FSReleaseDir) BuildRelease ¶
func (FSReleaseDir) DefaultName ¶
func (d FSReleaseDir) DefaultName() (string, error)
func (FSReleaseDir) FinalizeRelease ¶
func (d FSReleaseDir) FinalizeRelease(release boshrel.Release, force bool) error
func (FSReleaseDir) FindRelease ¶
func (FSReleaseDir) GenerateJob ¶
func (d FSReleaseDir) GenerateJob(name string) error
func (FSReleaseDir) GeneratePackage ¶
func (d FSReleaseDir) GeneratePackage(name string) error
func (FSReleaseDir) Init ¶
func (d FSReleaseDir) Init(git bool) error
func (FSReleaseDir) NextDevVersion ¶
func (FSReleaseDir) NextFinalVersion ¶
func (d FSReleaseDir) NextFinalVersion(name string) (semver.Version, error)
func (FSReleaseDir) Reset ¶
func (d FSReleaseDir) Reset() error
func (FSReleaseDir) VendorPackage ¶
func (d FSReleaseDir) VendorPackage(pkg *boshpkg.Package) error
type FSReleaseIndex ¶
type FSReleaseIndex struct {
// contains filtered or unexported fields
}
func NewFSReleaseIndex ¶
func NewFSReleaseIndex( name string, dirPath string, reporter ReleaseIndexReporter, uuidGen boshuuid.Generator, fs boshsys.FileSystem, ) FSReleaseIndex
func (FSReleaseIndex) Add ¶
func (i FSReleaseIndex) Add(manifest boshrelman.Manifest) error
func (FSReleaseIndex) Contains ¶
func (i FSReleaseIndex) Contains(release boshrel.Release) (bool, error)
func (FSReleaseIndex) LastVersion ¶
func (i FSReleaseIndex) LastVersion(name string) (*semver.Version, error)
func (FSReleaseIndex) ManifestPath ¶
func (i FSReleaseIndex) ManifestPath(name, version string) string
type GCSBlobstore ¶
type GCSBlobstore struct {
// contains filtered or unexported fields
}
func NewGCSBlobstore ¶
func NewGCSBlobstore( fs boshsys.FileSystem, uuidGen boshuuid.Generator, options map[string]interface{}, ) GCSBlobstore
func (GCSBlobstore) CleanUp ¶
func (b GCSBlobstore) CleanUp(path string) error
func (GCSBlobstore) Delete ¶
func (b GCSBlobstore) Delete(blobID string) error
func (GCSBlobstore) Validate ¶
func (b GCSBlobstore) Validate() error
type Provider ¶
type Provider struct {
// contains filtered or unexported fields
}
func NewProvider ¶
func NewProvider( indexReporter boshidx.Reporter, releaseIndexReporter ReleaseIndexReporter, blobsReporter BlobsDirReporter, releaseProvider boshrel.Provider, digestCalculator bicrypto.DigestCalculator, cmdRunner boshsys.CmdRunner, uuidGen boshuuid.Generator, timeService clock.Clock, fs boshsys.FileSystem, digestCreateAlgorithms []boshcrypto.Algorithm, logger boshlog.Logger, ) Provider
func (Provider) NewFSBlobsDir ¶
func (p Provider) NewFSBlobsDir(dirPath string) FSBlobsDir
func (Provider) NewFSReleaseDir ¶
func (p Provider) NewFSReleaseDir(dirPath string, parallel int) FSReleaseDir
func (Provider) NewReleaseReader ¶
func (p Provider) NewReleaseReader(dirPath string, parallel int) boshrel.BuiltReader
type ReleaseDir ¶
type ReleaseDir interface { Init(bool) error Reset() error GenerateJob(string) error GeneratePackage(string) error // DefaultName returns a string for the release. DefaultName() (string, error) // NextDevVersion and NextFinalVersion returns a next version for the that name. // It does not account for gaps and just plainly increments. NextDevVersion(name string, timestamp bool) (semver.Version, error) NextFinalVersion(name string) (semver.Version, error) // FindRelease returns last dev or final release version if it's empty; // otherwise it finds a release by given name and version. FindRelease(name string, version semver.Version) (boshrel.Release, error) // BuildRelease builds a new version of the Release // from the release directory by looking at jobs, packages, etc. directories. BuildRelease(name string, version semver.Version, force bool) (boshrel.Release, error) VendorPackage(*boshpkg.Package) error // FinalizeRelease adds the Release to the final list so that it's consumable by others. FinalizeRelease(release boshrel.Release, force bool) error }
type ReleaseIndex ¶
type ReleaseIndexReporter ¶
type S3Blobstore ¶
type S3Blobstore struct {
// contains filtered or unexported fields
}
func NewS3Blobstore ¶
func NewS3Blobstore( fs boshsys.FileSystem, uuidGen boshuuid.Generator, options map[string]interface{}, ) S3Blobstore
func (S3Blobstore) CleanUp ¶
func (b S3Blobstore) CleanUp(path string) error
func (S3Blobstore) Delete ¶
func (b S3Blobstore) Delete(blobID string) error
func (S3Blobstore) Validate ¶
func (b S3Blobstore) Validate() error
Source Files ¶
Directories ¶
Path | Synopsis |
---|---|
indexfakes
Code generated by counterfeiter.
|
Code generated by counterfeiter. |
Code generated by counterfeiter.
|
Code generated by counterfeiter. |
Click to show internal directories.
Click to hide internal directories.