forked from toolshed/abra
refactor: move app files from config to app package
This commit is contained in:
@ -11,6 +11,7 @@ import (
|
||||
"strings"
|
||||
"sync"
|
||||
|
||||
appPkg "coopcloud.tech/abra/pkg/app"
|
||||
"coopcloud.tech/abra/pkg/client"
|
||||
"coopcloud.tech/abra/pkg/config"
|
||||
"coopcloud.tech/abra/pkg/upstream/stack"
|
||||
@ -81,7 +82,7 @@ func GeneratePassphrases(count uint) ([]string, error) {
|
||||
// "app new" case where we pass in the .env.sample and the "secret generate"
|
||||
// case where the app is created.
|
||||
func ReadSecretsConfig(appEnvPath string, composeFiles []string, stackName string) (map[string]Secret, error) {
|
||||
appEnv, appModifiers, err := config.ReadEnvWithModifiers(appEnvPath)
|
||||
appEnv, appModifiers, err := appPkg.ReadEnvWithModifiers(appEnvPath)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
@ -240,10 +241,10 @@ type secretStatuses []secretStatus
|
||||
|
||||
// PollSecretsStatus checks status of secrets by comparing the local recipe
|
||||
// config and deploymend server state.
|
||||
func PollSecretsStatus(cl *dockerClient.Client, app config.App) (secretStatuses, error) {
|
||||
func PollSecretsStatus(cl *dockerClient.Client, app appPkg.App) (secretStatuses, error) {
|
||||
var secStats secretStatuses
|
||||
|
||||
composeFiles, err := config.GetComposeFiles(app.Recipe, app.Env)
|
||||
composeFiles, err := appPkg.GetComposeFiles(app.Recipe, app.Env)
|
||||
if err != nil {
|
||||
return secStats, err
|
||||
}
|
||||
|
Reference in New Issue
Block a user