Switch to using const for max docker secret length.
continuous-integration/drone/pr Build is failing
Details
continuous-integration/drone/pr Build is failing
Details
This commit is contained in:
parent
f85a3e40aa
commit
344590b19b
|
@ -269,8 +269,8 @@ func ensureSecretLengths(secrets map[string]string, domainName string, sanitised
|
|||
domainAndFormatLength := len(sanitisedAppName) + 4
|
||||
for secretName := range secrets {
|
||||
|
||||
if len(secretName)+domainAndFormatLength > 64 {
|
||||
return fmt.Errorf("%s is too long (> 64 chars when combined with %s)", secretName, sanitisedAppName)
|
||||
if len(secretName)+domainAndFormatLength > config.MAX_DOCKER_SECRET_LENGTH {
|
||||
return fmt.Errorf("%s is too long (> %d chars when combined with %s)", secretName, config.MAX_DOCKER_SECRET_LENGTH, sanitisedAppName)
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -35,6 +35,7 @@ var CATALOGUE_JSON_REPO_NAME = "recipes-catalogue-json"
|
|||
var SSH_URL_TEMPLATE = "ssh://git@git.coopcloud.tech:2222/coop-cloud/%s.git"
|
||||
|
||||
const MAX_SANITISED_APP_NAME_LENGTH = 45
|
||||
const MAX_DOCKER_SECRET_LENGTH = 64
|
||||
|
||||
// GetServers retrieves all servers.
|
||||
func GetServers() ([]string, error) {
|
||||
|
|
Loading…
Reference in New Issue