Documentation
¶
Overview ¶
Package resolver tries to provide the environment specific Git reference for the release source repository. This Git reference tells us which version of our service releases to consider, based on the environment Kayron is running in.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IsReleaseNotFound ¶
func Search ¶
Search determines the Git ref to use for the given environment. Search will never return an empty ref, but instead resolve the SHA of the Git commit at HEAD of the default branch.
production resolve the latest release tag
staging resolve the latest commit sha of the default branch
testing resolve the latest commit sha of the branch matching the test
environment, if such a branch exists, otherwise fall back to
the commit sha of the default branch
Types ¶
type Interface ¶
type Interface interface {
// Commit returns the most recent Git commit at the given ref for the
// underlying Github repository.
Commit(string) (string, error)
// Latest returns the most recent Git tag for the latest release of the
// underlying Github repository.
Latest() (string, error)
}
Interface defines a network abstraction that we want to control in order to verify the business logic of resolver.Search during unit tests.
Click to show internal directories.
Click to hide internal directories.