refactor/fix: deploy/upgrade/rollback

See coop-cloud/abra#461
This commit is contained in:
2025-01-01 19:15:22 +01:00
parent 5975be6870
commit b0cd8ccbb9
85 changed files with 783 additions and 7118 deletions

View File

@ -159,11 +159,11 @@ func Get(name string) Recipe {
dir := path.Join(config.RECIPES_DIR, escapeRecipeName(name))
r := Recipe{
Name: name,
Version: version,
Dir: dir,
GitURL: gitURL,
SSHURL: sshURL,
Name: name,
EnvVersion: version,
Dir: dir,
GitURL: gitURL,
SSHURL: sshURL,
ComposePath: path.Join(dir, "compose.yml"),
ReadmePath: path.Join(dir, "README.md"),
@ -179,12 +179,12 @@ func Get(name string) Recipe {
}
type Recipe struct {
Name string
Version string
Dirty bool // NOTE(d1): git terminology for unstaged changes
Dir string
GitURL string
SSHURL string
Name string
EnvVersion string
Dirty bool // NOTE(d1): git terminology for unstaged changes
Dir string
GitURL string
SSHURL string
ComposePath string
ReadmePath string
@ -195,7 +195,7 @@ type Recipe struct {
// String outputs a human-friendly string representation.
func (r Recipe) String() string {
out := fmt.Sprintf("{name: %s, ", r.Name)
out += fmt.Sprintf("version : %s, ", r.Version)
out += fmt.Sprintf("version : %s, ", r.EnvVersion)
out += fmt.Sprintf("dirty: %v, ", r.Dirty)
out += fmt.Sprintf("dir: %s, ", r.Dir)
out += fmt.Sprintf("git url: %s, ", r.GitURL)