Compare commits

...

11 Commits

Author SHA1 Message Date
3wc
bef92d53a8 fix: don't translate blank string
Some checks failed
continuous-integration/drone/push Build is failing
2025-09-05 13:33:51 -04:00
3wc
a4b47b431b fix: temporary fix to #648
Some checks failed
continuous-integration/drone/pr Build is failing
continuous-integration/drone/push Build is failing
2025-09-05 13:29:31 -04:00
bddf8039af test: ensure previous versions not deleted
All checks were successful
continuous-integration/drone/push Build is passing
See #615
2025-09-04 08:26:21 +00:00
d74e760940 Update translation files
All checks were successful
continuous-integration/drone/push Build is passing
Updated by "Update PO files to match POT (msgmerge)" add-on in Weblate.

Translation: Co-op Cloud/abra
Translate-URL: https://translate.coopcloud.tech/projects/co-op-cloud/abra/
2025-09-04 08:14:12 +00:00
7f75d25d56 Translated using Weblate (Spanish)
Currently translated at 10.4% (116 of 1105 strings)

Translation: Co-op Cloud/abra
Translate-URL: https://translate.coopcloud.tech/projects/co-op-cloud/abra/es/
2025-09-04 08:14:12 +00:00
3wc
0bb6d9609c Add test to make sure non-chaos hash deploy fails..
All checks were successful
continuous-integration/drone/push Build is passing
..and make sure _ensure_env_version passes through variable correctly.
2025-09-03 14:25:42 -04:00
3wc
e858dcdd14 Whoops, gettext 2025-09-03 14:25:41 -04:00
3wc
3606349a4a Error out if env version is chaos-y and --chaos not provided
Re #554
2025-09-03 14:25:22 -04:00
4547cf2579 fix: help/version override for translation
All checks were successful
continuous-integration/drone/pr Build is passing
continuous-integration/drone/push Build is passing
See #628
2025-09-03 08:58:31 +02:00
e1f029d2db chore: make i18n
All checks were successful
continuous-integration/drone/push Build is passing
2025-09-03 00:25:23 +02:00
cf2952dc65 chore: add missing i18n on --latest [ci skip] 2025-09-03 00:24:55 +02:00
9 changed files with 314 additions and 118 deletions

View File

@ -108,10 +108,13 @@ checkout as-is. Recipe commit hashes are also supported as values for
}
if !internal.Chaos {
_, err = app.Recipe.EnsureVersion(toDeployVersion)
isChaos, err := app.Recipe.EnsureVersion(toDeployVersion)
if err != nil {
log.Fatal(i18n.G("ensure recipe: %s", err))
}
if isChaos {
log.Fatal(i18n.G("version '%s' appears to be a chaos commit, but --chaos/-C was not provided", toDeployVersion))
}
}
if err := lint.LintForErrors(app.Recipe); err != nil {
@ -367,8 +370,8 @@ func init() {
AppDeployCommand.PersistentFlags().BoolVarP(
&internal.DeployLatest,
"latest",
"l",
i18n.G("latest"),
i18n.G("l"),
false,
i18n.G("deploy latest recipe version"),
)

View File

@ -5,6 +5,8 @@ var (
Debug bool
NoInput bool
Offline bool
Help bool
Version bool
// NOTE(d1): sub-command specific
Chaos bool

View File

@ -47,6 +47,29 @@ Additional help topics:{{range .Commands}}{{if .IsAdditionalHelpTopicCommand}}
Use "{{.CommandPath}} [command] --help" for more information about a command.{{end}}
`)
helpCmd = &cobra.Command{
Use: i18n.G("help [command]"),
// translators: Short description for `help` command
Short: i18n.G("Help about any command"),
Long: i18n.G(`Help provides help for any command in the application.
Simply type abra help [path to command] for full details.`),
Run: func(c *cobra.Command, args []string) {
cmd, _, e := c.Root().Find(args)
if cmd == nil || e != nil {
c.Print(i18n.G("unknown help topic %#q\n", args))
if err := c.Root().Usage(); err != nil {
log.Fatal(err)
}
} else {
cmd.InitDefaultHelpFlag()
cmd.InitDefaultVersionFlag()
if err := cmd.Help(); err != nil {
log.Fatal(err)
}
}
},
}
)
func Run(version, commit string) {
@ -122,6 +145,7 @@ Config:
rootCmd.CompletionOptions.DisableDefaultCmd = true
rootCmd.SetUsageTemplate(usageTemplate)
rootCmd.SetHelpCommand(helpCmd)
// translators: `abra man` aliases. use a comma separated list of aliases
// with no spaces in between
@ -185,6 +209,24 @@ Config:
i18n.G("prefer offline & filesystem access"),
)
rootCmd.PersistentFlags().BoolVarP(
&internal.Help,
i18n.G("help"),
i18n.G("h"),
false,
i18n.G("help for abra"),
)
rootCmd.PersistentFlags().BoolVarP(
&internal.Version,
i18n.G("version"),
// FIXME: temporary workaround for #648
// i18n.G("v"),
"",
false,
i18n.G("version for abra"),
)
catalogue.CatalogueCommand.AddCommand(
catalogue.CatalogueGenerateCommand,
catalogue.CatalogueSyncCommand,

View File

@ -7,7 +7,7 @@
msgid ""
msgstr "Project-Id-Version: \n"
"Report-Msgid-Bugs-To: EMAIL\n"
"POT-Creation-Date: 2025-09-01 13:48+0200\n"
"POT-Creation-Date: 2025-09-03 14:25-0400\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@ -43,7 +43,7 @@ msgid " # fetch from recipe catalogue\n"
" abra recipe fetch gitea --ssh"
msgstr ""
#: ./cli/run.go:136
#: ./cli/run.go:160
msgid " # generate the man pages into /usr/local/share/man/man1\n"
" abra_path=$(which abra) # pass abra absolute path to sudo below\n"
" sudo $abra_path man\n"
@ -361,7 +361,7 @@ msgstr ""
msgid "%s is still deployed. Run \"abra app undeploy %s\""
msgstr ""
#: ./cli/app/deploy.go:172 ./cli/app/upgrade.go:214
#: ./cli/app/deploy.go:175 ./cli/app/upgrade.go:214
#, c-format
msgid "%s missing from %s.env"
msgstr ""
@ -582,7 +582,7 @@ msgstr ""
msgid "Both local recipe and live deployment labels are shown."
msgstr ""
#: ./cli/app/backup.go:319 ./cli/app/backup.go:335 ./cli/app/check.go:95 ./cli/app/cmd.go:285 ./cli/app/cp.go:385 ./cli/app/deploy.go:339 ./cli/app/labels.go:143 ./cli/app/new.go:377 ./cli/app/ps.go:213 ./cli/app/restart.go:162 ./cli/app/restore.go:138 ./cli/app/secret.go:569 ./cli/app/secret.go:609 ./cli/app/secret.go:633 ./cli/app/secret.go:641 ./cli/catalogue/catalogue.go:318 ./cli/recipe/lint.go:137 ./cli/updater/updater.go:552
#: ./cli/app/backup.go:319 ./cli/app/backup.go:335 ./cli/app/check.go:95 ./cli/app/cmd.go:285 ./cli/app/cp.go:385 ./cli/app/deploy.go:342 ./cli/app/labels.go:143 ./cli/app/new.go:377 ./cli/app/ps.go:213 ./cli/app/restart.go:162 ./cli/app/restore.go:138 ./cli/app/secret.go:569 ./cli/app/secret.go:609 ./cli/app/secret.go:633 ./cli/app/secret.go:641 ./cli/catalogue/catalogue.go:318 ./cli/recipe/lint.go:137 ./cli/updater/updater.go:552
msgid "C"
msgstr ""
@ -724,7 +724,7 @@ msgid "Creates a new app from a default recipe.\n"
"on your $PATH."
msgstr ""
#: ./cli/app/deploy.go:355 ./cli/app/new.go:353 ./cli/app/rollback.go:337 ./cli/app/upgrade.go:447
#: ./cli/app/deploy.go:358 ./cli/app/new.go:353 ./cli/app/rollback.go:337 ./cli/app/upgrade.go:447
msgid "D"
msgstr ""
@ -857,7 +857,7 @@ msgid "Generate labels for the main recipe service.\n"
msgstr ""
#. translators: Short description for `man` command
#: ./cli/run.go:135
#: ./cli/run.go:159
msgid "Generate manpage"
msgstr ""
@ -887,6 +887,16 @@ msgstr ""
msgid "HOST"
msgstr ""
#. translators: Short description for `help` command
#: ./cli/run.go:54
msgid "Help about any command"
msgstr ""
#: ./cli/run.go:55
msgid "Help provides help for any command in the application.\n"
"Simply type abra help [path to command] for full details."
msgstr ""
#: ./cli/app/ps.go:187 ./cli/recipe/version.go:69
msgid "IMAGE"
msgstr ""
@ -1304,14 +1314,14 @@ msgid "The Co-op Cloud auto-updater 🤖 🚀"
msgstr ""
#. translators: Short description for `abra` binary
#: ./cli/run.go:57
#: ./cli/run.go:80
msgid "The Co-op Cloud command-line utility belt 🎩🐇"
msgstr ""
#. translators: Long description for `abra` binary. This needs to be
#. translated in the same way as the Short description so that everything
#. matches up
#: ./cli/run.go:61
#: ./cli/run.go:84
#, c-format
msgid "The Co-op Cloud command-line utility belt 🎩🐇\n"
"\n"
@ -1637,7 +1647,7 @@ msgid "aborting as requested"
msgstr ""
#. translators: `abra` binary name
#: ./cli/run.go:55
#: ./cli/run.go:78
msgid "abra [cmd] [args] [flags]"
msgstr ""
@ -1645,7 +1655,7 @@ msgstr ""
msgid "abra app labels 1312.net"
msgstr ""
#: ./cli/run.go:114
#: ./cli/run.go:137
#, c-format
msgid "abra version: %s, commit: %s, lang: %s"
msgstr ""
@ -1721,7 +1731,7 @@ msgid "ambiguous service list received, prompting for input"
msgstr ""
#. translators: `abra app` command for autocompletion
#: ./cli/run.go:68
#: ./cli/run.go:91
msgid "app"
msgstr ""
@ -1763,7 +1773,7 @@ msgstr ""
msgid "attempting to run %s"
msgstr ""
#: ./cli/app/deploy.go:235 ./cli/app/upgrade.go:273
#: ./cli/app/deploy.go:238 ./cli/app/upgrade.go:273
#, c-format
msgid "attempting to run post deploy commands, saw: %s"
msgstr ""
@ -1779,7 +1789,7 @@ msgid "attempting to scale %s to 1"
msgstr ""
#. translators: `abra autocomplete` command for autocompletion
#: ./cli/run.go:70
#: ./cli/run.go:93
msgid "autocomplete"
msgstr ""
@ -1853,7 +1863,7 @@ msgstr ""
#. no spaces in between
#. translators: `abra app cp` aliases. use a comma separated list of aliases with
#. no spaces in between
#: ./cli/app/backup.go:148 ./cli/app/cp.go:30 ./cli/app/deploy.go:363 ./cli/app/rollback.go:345 ./cli/app/upgrade.go:455
#: ./cli/app/backup.go:148 ./cli/app/cp.go:30 ./cli/app/deploy.go:366 ./cli/app/rollback.go:345 ./cli/app/upgrade.go:455
msgid "c"
msgstr ""
@ -1922,7 +1932,7 @@ msgstr ""
msgid "cannot use '[secret] [version]' and '--all' together"
msgstr ""
#: ./cli/app/deploy.go:274
#: ./cli/app/deploy.go:277
msgid "cannot use --chaos and --latest together"
msgstr ""
@ -1946,16 +1956,16 @@ msgstr ""
msgid "cannot use [service] and --all-services/-a together"
msgstr ""
#: ./cli/app/deploy.go:266 ./cli/app/new.go:76
#: ./cli/app/deploy.go:269 ./cli/app/new.go:76
msgid "cannot use [version] and --chaos together"
msgstr ""
#: ./cli/app/deploy.go:270
#: ./cli/app/deploy.go:273
msgid "cannot use [version] and --latest together"
msgstr ""
#. translators: `abra catalogue` command for autocompletion
#: ./cli/run.go:72
#: ./cli/run.go:95
msgid "catalogue"
msgstr ""
@ -1982,7 +1992,7 @@ msgstr ""
msgid "cfg"
msgstr ""
#: ./cli/app/backup.go:318 ./cli/app/backup.go:334 ./cli/app/check.go:94 ./cli/app/cmd.go:284 ./cli/app/cp.go:384 ./cli/app/deploy.go:338 ./cli/app/labels.go:142 ./cli/app/new.go:376 ./cli/app/ps.go:212 ./cli/app/restart.go:161 ./cli/app/restore.go:137 ./cli/app/secret.go:568 ./cli/app/secret.go:608 ./cli/app/secret.go:632 ./cli/app/secret.go:640 ./cli/catalogue/catalogue.go:317 ./cli/recipe/lint.go:136 ./cli/updater/updater.go:551
#: ./cli/app/backup.go:318 ./cli/app/backup.go:334 ./cli/app/check.go:94 ./cli/app/cmd.go:284 ./cli/app/cp.go:384 ./cli/app/deploy.go:341 ./cli/app/labels.go:142 ./cli/app/new.go:376 ./cli/app/ps.go:212 ./cli/app/restart.go:161 ./cli/app/restore.go:137 ./cli/app/secret.go:568 ./cli/app/secret.go:608 ./cli/app/secret.go:632 ./cli/app/secret.go:640 ./cli/catalogue/catalogue.go:317 ./cli/recipe/lint.go:136 ./cli/updater/updater.go:551
msgid "chaos"
msgstr ""
@ -2328,7 +2338,7 @@ msgstr ""
msgid "deploy labels stanza present"
msgstr ""
#: ./cli/app/deploy.go:373
#: ./cli/app/deploy.go:376
msgid "deploy latest recipe version"
msgstr ""
@ -2405,11 +2415,11 @@ msgstr ""
msgid "dirty: %v, "
msgstr ""
#: ./cli/app/deploy.go:365 ./cli/app/rollback.go:347 ./cli/app/upgrade.go:457
#: ./cli/app/deploy.go:368 ./cli/app/rollback.go:347 ./cli/app/upgrade.go:457
msgid "disable converge logic checks"
msgstr ""
#: ./cli/app/deploy.go:357 ./cli/app/rollback.go:339 ./cli/app/upgrade.go:449
#: ./cli/app/deploy.go:360 ./cli/app/rollback.go:339 ./cli/app/upgrade.go:449
msgid "disable public DNS checks"
msgstr ""
@ -2438,7 +2448,7 @@ msgstr ""
msgid "domain name for app"
msgstr ""
#: ./cli/run.go:160
#: ./cli/run.go:184
msgid "don't forget to run 'sudo mandb'"
msgstr ""
@ -2647,7 +2657,7 @@ msgstr ""
#. translators: `abra recipe fetch` aliases. use a comma separated list of aliases
#. with no spaces in between
#: ./cli/app/deploy.go:347 ./cli/app/remove.go:163 ./cli/app/rollback.go:329 ./cli/app/secret.go:593 ./cli/app/upgrade.go:439 ./cli/app/volume.go:217 ./cli/recipe/fetch.go:20 ./cli/recipe/fetch.go:138
#: ./cli/app/deploy.go:350 ./cli/app/remove.go:163 ./cli/app/rollback.go:329 ./cli/app/secret.go:593 ./cli/app/upgrade.go:439 ./cli/app/volume.go:217 ./cli/recipe/fetch.go:20 ./cli/recipe/fetch.go:138
msgid "f"
msgstr ""
@ -2883,7 +2893,7 @@ msgstr ""
msgid "for %s read env %s with value: %s from docker service"
msgstr ""
#: ./cli/app/deploy.go:346 ./cli/app/remove.go:162 ./cli/app/rollback.go:328 ./cli/app/upgrade.go:438 ./cli/app/volume.go:216 ./cli/recipe/fetch.go:137
#: ./cli/app/deploy.go:349 ./cli/app/remove.go:162 ./cli/app/rollback.go:328 ./cli/app/upgrade.go:438 ./cli/app/volume.go:216 ./cli/recipe/fetch.go:137
msgid "force"
msgstr ""
@ -3055,6 +3065,10 @@ msgstr ""
msgid "git: opening repository in %s"
msgstr ""
#: ./cli/run.go:215
msgid "h"
msgstr ""
#: ./cli/recipe/new.go:94
msgid "happy hacking 🎉"
msgstr ""
@ -3071,6 +3085,18 @@ msgstr ""
msgid "healthcheck enabled for all services"
msgstr ""
#: ./cli/run.go:214
msgid "help"
msgstr ""
#: ./cli/run.go:52
msgid "help [command]"
msgstr ""
#: ./cli/run.go:217
msgid "help for abra"
msgstr ""
#: ./cli/app/restore.go:129
msgid "hooks"
msgstr ""
@ -3086,7 +3112,7 @@ msgstr ""
msgid "id: %s, "
msgstr ""
#: ./cli/app/backup.go:321 ./cli/app/backup.go:337 ./cli/app/check.go:97 ./cli/app/cmd.go:287 ./cli/app/cp.go:387 ./cli/app/deploy.go:341 ./cli/app/labels.go:145 ./cli/app/new.go:379 ./cli/app/ps.go:215 ./cli/app/restart.go:164 ./cli/app/restore.go:140 ./cli/app/secret.go:571 ./cli/app/secret.go:611 ./cli/app/secret.go:635 ./cli/app/secret.go:643 ./cli/catalogue/catalogue.go:320 ./cli/recipe/lint.go:139 ./cli/updater/updater.go:554
#: ./cli/app/backup.go:321 ./cli/app/backup.go:337 ./cli/app/check.go:97 ./cli/app/cmd.go:287 ./cli/app/cp.go:387 ./cli/app/deploy.go:344 ./cli/app/labels.go:145 ./cli/app/new.go:379 ./cli/app/ps.go:215 ./cli/app/restart.go:164 ./cli/app/restore.go:140 ./cli/app/secret.go:571 ./cli/app/secret.go:611 ./cli/app/secret.go:635 ./cli/app/secret.go:643 ./cli/catalogue/catalogue.go:320 ./cli/recipe/lint.go:139 ./cli/updater/updater.go:554
msgid "ignore uncommitted recipes changes"
msgstr ""
@ -3279,7 +3305,7 @@ msgstr ""
#. no spaces in between
#. translators: `abra recipe lint` aliases. use a comma separated list of
#. aliases with no spaces in between
#: ./cli/app/cmd.go:261 ./cli/app/logs.go:20 ./cli/recipe/lint.go:17 ./cli/server/add.go:207
#: ./cli/app/cmd.go:261 ./cli/app/deploy.go:374 ./cli/app/logs.go:20 ./cli/recipe/lint.go:17 ./cli/server/add.go:207
msgid "l"
msgstr ""
@ -3288,7 +3314,7 @@ msgstr ""
msgid "labels <domain> [flags]"
msgstr ""
#: ./cli/app/list.go:183
#: ./cli/app/deploy.go:373 ./cli/app/list.go:183
msgid "latest"
msgstr ""
@ -3411,7 +3437,7 @@ msgstr ""
#. with no spaces in between
#. translators: `abra man` aliases. use a comma separated list of aliases
#. with no spaces in between
#: ./cli/app/list.go:318 ./cli/app/move.go:34 ./cli/app/ps.go:205 ./cli/app/secret.go:553 ./cli/app/secret.go:649 ./cli/recipe/list.go:104 ./cli/recipe/upgrade.go:376 ./cli/recipe/version.go:139 ./cli/run.go:128 ./cli/server/list.go:106 ./cli/updater/updater.go:560
#: ./cli/app/list.go:318 ./cli/app/move.go:34 ./cli/app/ps.go:205 ./cli/app/secret.go:553 ./cli/app/secret.go:649 ./cli/recipe/list.go:104 ./cli/recipe/upgrade.go:376 ./cli/recipe/version.go:139 ./cli/run.go:152 ./cli/server/list.go:106 ./cli/updater/updater.go:560
msgid "m"
msgstr ""
@ -3434,12 +3460,12 @@ msgid "malformed version pin specification: %s"
msgstr ""
#. translators: `abra man` command for autocompletion
#: ./cli/run.go:74
#: ./cli/run.go:97
msgid "man"
msgstr ""
#. translators: `man` command
#: ./cli/run.go:132
#: ./cli/run.go:156
msgid "man [flags]"
msgstr ""
@ -3741,11 +3767,11 @@ msgstr ""
msgid "no volumes to remove"
msgstr ""
#: ./cli/app/deploy.go:362 ./cli/app/rollback.go:344 ./cli/app/upgrade.go:454
#: ./cli/app/deploy.go:365 ./cli/app/rollback.go:344 ./cli/app/upgrade.go:454
msgid "no-converge-checks"
msgstr ""
#: ./cli/app/deploy.go:354 ./cli/app/rollback.go:336 ./cli/app/upgrade.go:446
#: ./cli/app/deploy.go:357 ./cli/app/rollback.go:336 ./cli/app/upgrade.go:446
msgid "no-domain-checks"
msgstr ""
@ -3881,7 +3907,7 @@ msgstr ""
msgid "pattern"
msgstr ""
#: ./cli/app/deploy.go:349 ./cli/app/remove.go:165 ./cli/app/rollback.go:331 ./cli/app/upgrade.go:441 ./cli/app/volume.go:219
#: ./cli/app/deploy.go:352 ./cli/app/remove.go:165 ./cli/app/rollback.go:331 ./cli/app/upgrade.go:441 ./cli/app/volume.go:219
msgid "perform action without further prompt"
msgstr ""
@ -3918,7 +3944,7 @@ msgstr ""
msgid "polling undeploy status"
msgstr ""
#: ./cli/run.go:185
#: ./cli/run.go:209
msgid "prefer offline & filesystem access"
msgstr ""
@ -4054,7 +4080,7 @@ msgid "readme: %s, "
msgstr ""
#. translators: `abra recipe` command for autocompletion
#: ./cli/app/list.go:302 ./cli/app/list.go:309 ./cli/run.go:76
#: ./cli/app/list.go:302 ./cli/app/list.go:309 ./cli/run.go:99
msgid "recipe"
msgstr ""
@ -4396,7 +4422,7 @@ msgstr ""
msgid "run command locally"
msgstr ""
#: ./cli/app/deploy.go:233 ./cli/app/upgrade.go:270
#: ./cli/app/deploy.go:236 ./cli/app/upgrade.go:270
#, c-format
msgid "run the following post-deploy commands: %s"
msgstr ""
@ -4476,7 +4502,7 @@ msgstr ""
msgid "secret not found: %s"
msgstr ""
#: ./cli/app/deploy.go:288
#: ./cli/app/deploy.go:291
#, c-format
msgid "secret not generated: %s"
msgstr ""
@ -4496,7 +4522,7 @@ msgid "secrets are %s shown again, please save them %s"
msgstr ""
#. translators: `abra server` command for autocompletion
#: ./cli/app/list.go:325 ./cli/app/list.go:332 ./cli/app/new.go:337 ./cli/app/new.go:344 ./cli/run.go:78
#: ./cli/app/list.go:325 ./cli/app/list.go:332 ./cli/app/new.go:337 ./cli/app/new.go:344 ./cli/run.go:101
msgid "server"
msgstr ""
@ -4612,7 +4638,7 @@ msgstr ""
msgid "show apps of a specific server"
msgstr ""
#: ./cli/run.go:169 ./cli/updater/updater.go:507
#: ./cli/run.go:193 ./cli/updater/updater.go:507
msgid "show debug messages"
msgstr ""
@ -4660,11 +4686,11 @@ msgstr ""
msgid "skipping converge logic checks"
msgstr ""
#: ./cli/app/deploy.go:186
#: ./cli/app/deploy.go:189
msgid "skipping domain checks"
msgstr ""
#: ./cli/app/deploy.go:183
#: ./cli/app/deploy.go:186
msgid "skipping domain checks, no DOMAIN=... configured"
msgstr ""
@ -4893,7 +4919,7 @@ msgstr ""
msgid "tmpfs options are incompatible with type volume"
msgstr ""
#: ./cli/run.go:177 ./cli/updater/updater.go:515
#: ./cli/run.go:201 ./cli/updater/updater.go:515
msgid "toggle non-interactive mode"
msgstr ""
@ -4977,7 +5003,7 @@ msgstr ""
msgid "unable to convert to JSON: %s"
msgstr ""
#: ./cli/run.go:94
#: ./cli/run.go:117
#, c-format
msgid "unable to create %s: %s"
msgstr ""
@ -5071,7 +5097,7 @@ msgstr ""
msgid "unable to parse '%s' value as bool: %s"
msgstr ""
#: ./cli/run.go:152
#: ./cli/run.go:176
#, c-format
msgid "unable to proceed, %s does not exist?"
msgstr ""
@ -5227,6 +5253,11 @@ msgstr ""
msgid "unknown deployed version, unable to upgrade"
msgstr ""
#: ./cli/run.go:60
#, c-format
msgid "unknown help topic %#q\n"
msgstr ""
#: ./pkg/upstream/convert/service.go:780
#, c-format
msgid "unknown mode: %s"
@ -5268,7 +5299,7 @@ msgid "updating %s to %s in %s"
msgstr ""
#. translators: `abra upgrade` command for autocompletion
#: ./cli/run.go:80
#: ./cli/run.go:103
msgid "upgrade"
msgstr ""
@ -5343,7 +5374,7 @@ msgstr ""
#. translators: `abra recipe versions` aliases. use a comma separated list of aliases
#. with no spaces in between
#: ./cli/app/backup.go:311 ./cli/app/restore.go:122 ./cli/recipe/version.go:19 ./cli/server/prune.go:107
#: ./cli/app/backup.go:311 ./cli/app/restore.go:122 ./cli/recipe/version.go:19 ./cli/run.go:223 ./cli/server/prune.go:107
msgid "v"
msgstr ""
@ -5371,16 +5402,29 @@ msgstr ""
msgid "vendor config versions in an abra.sh"
msgstr ""
#: ./cli/run.go:222
msgid "version"
msgstr ""
#: ./pkg/app/app.go:688
#, c-format
msgid "version %s saved to %s.env"
msgstr ""
#: ./cli/app/deploy.go:116
#, c-format
msgid "version '%s' appears to be a chaos commit, but --chaos/-C was not provided"
msgstr ""
#: ./pkg/recipe/recipe.go:200
#, c-format
msgid "version : %s, "
msgstr ""
#: ./cli/run.go:225
msgid "version for abra"
msgstr ""
#: ./pkg/recipe/recipe.go:130
#, c-format
msgid "version seems invalid: %s"
@ -5391,32 +5435,32 @@ msgstr ""
msgid "version wiped from %s.env"
msgstr ""
#: ./cli/app/deploy.go:315
#: ./cli/app/deploy.go:318
#, c-format
msgid "version: can not redeploy chaos version %s"
msgstr ""
#: ./cli/app/deploy.go:302
#: ./cli/app/deploy.go:305
#, c-format
msgid "version: taking chaos version: %s"
msgstr ""
#: ./cli/app/deploy.go:323
#: ./cli/app/deploy.go:326
#, c-format
msgid "version: taking deployed version: %s"
msgstr ""
#: ./cli/app/deploy.go:328
#: ./cli/app/deploy.go:331
#, c-format
msgid "version: taking new recipe version: %s"
msgstr ""
#: ./cli/app/deploy.go:317
#: ./cli/app/deploy.go:320
#, c-format
msgid "version: taking version from .env file: %s"
msgstr ""
#: ./cli/app/deploy.go:308
#: ./cli/app/deploy.go:311
#, c-format
msgid "version: taking version from cli arg: %s"
msgstr ""
@ -5539,7 +5583,7 @@ msgstr ""
msgid "writer: %v, "
msgstr ""
#: ./cli/app/deploy.go:240 ./cli/app/new.go:221 ./cli/app/rollback.go:232 ./cli/app/undeploy.go:111 ./cli/app/upgrade.go:278
#: ./cli/app/deploy.go:243 ./cli/app/new.go:221 ./cli/app/rollback.go:232 ./cli/app/undeploy.go:111 ./cli/app/upgrade.go:278
#, c-format
msgid "writing recipe version failed: %s"
msgstr ""

Binary file not shown.

View File

@ -2,8 +2,8 @@ msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: EMAIL\n"
"POT-Creation-Date: 2025-09-01 13:48+0200\n"
"PO-Revision-Date: 2025-08-29 21:45+0000\n"
"POT-Creation-Date: 2025-09-03 14:25-0400\n"
"PO-Revision-Date: 2025-09-04 08:14+0000\n"
"Last-Translator: chasqui <chasqui@cryptolab.net>\n"
"Language-Team: Spanish <https://translate.coopcloud.tech/projects/co-op-"
"cloud/abra/es/>\n"
@ -44,7 +44,7 @@ msgid ""
" abra recipe fetch gitea --ssh"
msgstr ""
#: cli/run.go:136
#: cli/run.go:160
msgid ""
" # generate the man pages into /usr/local/share/man/man1\n"
" abra_path=$(which abra) # pass abra absolute path to sudo below\n"
@ -376,7 +376,7 @@ msgstr ""
msgid "%s is still deployed. Run \"abra app undeploy %s\""
msgstr ""
#: cli/app/deploy.go:172 cli/app/upgrade.go:214
#: cli/app/deploy.go:175 cli/app/upgrade.go:214
#, c-format
msgid "%s missing from %s.env"
msgstr ""
@ -610,7 +610,7 @@ msgid "Both local recipe and live deployment labels are shown."
msgstr ""
#: cli/app/backup.go:319 cli/app/backup.go:335 cli/app/check.go:95
#: cli/app/cmd.go:285 cli/app/cp.go:385 cli/app/deploy.go:339
#: cli/app/cmd.go:285 cli/app/cp.go:385 cli/app/deploy.go:342
#: cli/app/labels.go:143 cli/app/new.go:377 cli/app/ps.go:213
#: cli/app/restart.go:162 cli/app/restore.go:138 cli/app/secret.go:569
#: cli/app/secret.go:609 cli/app/secret.go:633 cli/app/secret.go:641
@ -700,7 +700,7 @@ msgstr "🚀 Crea una nueva plataforma"
#. translators: Short description for `abra recipe new` command
#: cli/recipe/new.go:43
msgid "Create a new recipe"
msgstr ""
msgstr "Crear una nueva receta 🧑‍🍳"
#. translators: Short description for `app backup create` command
#: cli/app/backup.go:155
@ -777,7 +777,7 @@ msgid ""
"on your $PATH."
msgstr ""
#: cli/app/deploy.go:355 cli/app/new.go:353 cli/app/rollback.go:337
#: cli/app/deploy.go:358 cli/app/new.go:353 cli/app/rollback.go:337
#: cli/app/upgrade.go:447
msgid "D"
msgstr ""
@ -926,7 +926,7 @@ msgid ""
msgstr ""
#. translators: Short description for `man` command
#: cli/run.go:135
#: cli/run.go:159
msgid "Generate manpage"
msgstr "📒 Manual de uso"
@ -956,6 +956,17 @@ msgstr ""
msgid "HOST"
msgstr ""
#. translators: Short description for `help` command
#: cli/run.go:54
msgid "Help about any command"
msgstr ""
#: cli/run.go:55
msgid ""
"Help provides help for any command in the application.\n"
"Simply type abra help [path to command] for full details."
msgstr ""
#: cli/app/ps.go:187 cli/recipe/version.go:69
msgid "IMAGE"
msgstr ""
@ -1406,14 +1417,14 @@ msgid "The Co-op Cloud auto-updater 🤖 🚀"
msgstr "📨 Actualizador automático de Co-op Cloud 🤖 🚀"
#. translators: Short description for `abra` binary
#: cli/run.go:57
#: cli/run.go:80
msgid "The Co-op Cloud command-line utility belt 🎩🐇"
msgstr "La varita de mágica de Co-op Cloud 🪄🎩🐇"
#. translators: Long description for `abra` binary. This needs to be
#. translated in the same way as the Short description so that everything
#. matches up
#: cli/run.go:61
#: cli/run.go:84
#, fuzzy, c-format
msgid ""
"The Co-op Cloud command-line utility belt 🎩🐇\n"
@ -1800,7 +1811,7 @@ msgid "aborting as requested"
msgstr ""
#. translators: `abra` binary name
#: cli/run.go:55
#: cli/run.go:78
msgid "abra [cmd] [args] [flags]"
msgstr ""
@ -1808,7 +1819,7 @@ msgstr ""
msgid "abra app labels 1312.net"
msgstr ""
#: cli/run.go:114
#: cli/run.go:137
#, c-format
msgid "abra version: %s, commit: %s, lang: %s"
msgstr ""
@ -1885,7 +1896,7 @@ msgid "ambiguous service list received, prompting for input"
msgstr ""
#. translators: `abra app` command for autocompletion
#: cli/run.go:68
#: cli/run.go:91
msgid "app"
msgstr "plataforma"
@ -1927,7 +1938,7 @@ msgstr ""
msgid "attempting to run %s"
msgstr ""
#: cli/app/deploy.go:235 cli/app/upgrade.go:273
#: cli/app/deploy.go:238 cli/app/upgrade.go:273
#, c-format
msgid "attempting to run post deploy commands, saw: %s"
msgstr ""
@ -1943,7 +1954,7 @@ msgid "attempting to scale %s to 1"
msgstr ""
#. translators: `abra autocomplete` command for autocompletion
#: cli/run.go:70
#: cli/run.go:93
msgid "autocomplete"
msgstr ""
@ -2023,7 +2034,7 @@ msgstr ""
#. no spaces in between
#. translators: `abra app cp` aliases. use a comma separated list of aliases with
#. no spaces in between
#: cli/app/backup.go:148 cli/app/cp.go:30 cli/app/deploy.go:363
#: cli/app/backup.go:148 cli/app/cp.go:30 cli/app/deploy.go:366
#: cli/app/rollback.go:345 cli/app/upgrade.go:455
msgid "c"
msgstr ""
@ -2093,7 +2104,7 @@ msgstr ""
msgid "cannot use '[secret] [version]' and '--all' together"
msgstr ""
#: cli/app/deploy.go:274
#: cli/app/deploy.go:277
msgid "cannot use --chaos and --latest together"
msgstr ""
@ -2117,16 +2128,16 @@ msgstr ""
msgid "cannot use [service] and --all-services/-a together"
msgstr ""
#: cli/app/deploy.go:266 cli/app/new.go:76
#: cli/app/deploy.go:269 cli/app/new.go:76
msgid "cannot use [version] and --chaos together"
msgstr ""
#: cli/app/deploy.go:270
#: cli/app/deploy.go:273
msgid "cannot use [version] and --latest together"
msgstr ""
#. translators: `abra catalogue` command for autocompletion
#: cli/run.go:72
#: cli/run.go:95
msgid "catalogue"
msgstr ""
@ -2154,7 +2165,7 @@ msgid "cfg"
msgstr ""
#: cli/app/backup.go:318 cli/app/backup.go:334 cli/app/check.go:94
#: cli/app/cmd.go:284 cli/app/cp.go:384 cli/app/deploy.go:338
#: cli/app/cmd.go:284 cli/app/cp.go:384 cli/app/deploy.go:341
#: cli/app/labels.go:142 cli/app/new.go:376 cli/app/ps.go:212
#: cli/app/restart.go:161 cli/app/restore.go:137 cli/app/secret.go:568
#: cli/app/secret.go:608 cli/app/secret.go:632 cli/app/secret.go:640
@ -2512,7 +2523,7 @@ msgstr ""
msgid "deploy labels stanza present"
msgstr ""
#: cli/app/deploy.go:373
#: cli/app/deploy.go:376
#, fuzzy
msgid "deploy latest recipe version"
msgstr "Publicar una nueva versión de una receta"
@ -2590,11 +2601,11 @@ msgstr ""
msgid "dirty: %v, "
msgstr ""
#: cli/app/deploy.go:365 cli/app/rollback.go:347 cli/app/upgrade.go:457
#: cli/app/deploy.go:368 cli/app/rollback.go:347 cli/app/upgrade.go:457
msgid "disable converge logic checks"
msgstr ""
#: cli/app/deploy.go:357 cli/app/rollback.go:339 cli/app/upgrade.go:449
#: cli/app/deploy.go:360 cli/app/rollback.go:339 cli/app/upgrade.go:449
msgid "disable public DNS checks"
msgstr ""
@ -2623,7 +2634,7 @@ msgstr ""
msgid "domain name for app"
msgstr ""
#: cli/run.go:160
#: cli/run.go:184
msgid "don't forget to run 'sudo mandb'"
msgstr ""
@ -2839,7 +2850,7 @@ msgstr ""
#. translators: `abra recipe fetch` aliases. use a comma separated list of aliases
#. with no spaces in between
#: cli/app/deploy.go:347 cli/app/remove.go:163 cli/app/rollback.go:329
#: cli/app/deploy.go:350 cli/app/remove.go:163 cli/app/rollback.go:329
#: cli/app/secret.go:593 cli/app/upgrade.go:439 cli/app/volume.go:217
#: cli/recipe/fetch.go:20 cli/recipe/fetch.go:138
msgid "f"
@ -3077,7 +3088,7 @@ msgstr ""
msgid "for %s read env %s with value: %s from docker service"
msgstr ""
#: cli/app/deploy.go:346 cli/app/remove.go:162 cli/app/rollback.go:328
#: cli/app/deploy.go:349 cli/app/remove.go:162 cli/app/rollback.go:328
#: cli/app/upgrade.go:438 cli/app/volume.go:216 cli/recipe/fetch.go:137
msgid "force"
msgstr ""
@ -3250,6 +3261,10 @@ msgstr ""
msgid "git: opening repository in %s"
msgstr ""
#: cli/run.go:215
msgid "h"
msgstr ""
#: cli/recipe/new.go:94
msgid "happy hacking 🎉"
msgstr ""
@ -3266,6 +3281,19 @@ msgstr ""
msgid "healthcheck enabled for all services"
msgstr ""
#: cli/run.go:214
msgid "help"
msgstr ""
#: cli/run.go:52
#, fuzzy
msgid "help [command]"
msgstr "💻 Ejecutar comandos en una plataforma 🚀"
#: cli/run.go:217
msgid "help for abra"
msgstr ""
#: cli/app/restore.go:129
msgid "hooks"
msgstr ""
@ -3282,7 +3310,7 @@ msgid "id: %s, "
msgstr ""
#: cli/app/backup.go:321 cli/app/backup.go:337 cli/app/check.go:97
#: cli/app/cmd.go:287 cli/app/cp.go:387 cli/app/deploy.go:341
#: cli/app/cmd.go:287 cli/app/cp.go:387 cli/app/deploy.go:344
#: cli/app/labels.go:145 cli/app/new.go:379 cli/app/ps.go:215
#: cli/app/restart.go:164 cli/app/restore.go:140 cli/app/secret.go:571
#: cli/app/secret.go:611 cli/app/secret.go:635 cli/app/secret.go:643
@ -3482,8 +3510,8 @@ msgstr ""
#. no spaces in between
#. translators: `abra recipe lint` aliases. use a comma separated list of
#. aliases with no spaces in between
#: cli/app/cmd.go:261 cli/app/logs.go:20 cli/recipe/lint.go:17
#: cli/server/add.go:207
#: cli/app/cmd.go:261 cli/app/deploy.go:374 cli/app/logs.go:20
#: cli/recipe/lint.go:17 cli/server/add.go:207
msgid "l"
msgstr ""
@ -3492,7 +3520,7 @@ msgstr ""
msgid "labels <domain> [flags]"
msgstr "etiquetas <domain> [flags]"
#: cli/app/list.go:183
#: cli/app/deploy.go:373 cli/app/list.go:183
msgid "latest"
msgstr ""
@ -3619,7 +3647,7 @@ msgstr "plataformas"
#. with no spaces in between
#: cli/app/list.go:318 cli/app/move.go:34 cli/app/ps.go:205
#: cli/app/secret.go:553 cli/app/secret.go:649 cli/recipe/list.go:104
#: cli/recipe/upgrade.go:376 cli/recipe/version.go:139 cli/run.go:128
#: cli/recipe/upgrade.go:376 cli/recipe/version.go:139 cli/run.go:152
#: cli/server/list.go:106 cli/updater/updater.go:560
msgid "m"
msgstr ""
@ -3647,12 +3675,12 @@ msgid "malformed version pin specification: %s"
msgstr ""
#. translators: `abra man` command for autocompletion
#: cli/run.go:74
#: cli/run.go:97
msgid "man"
msgstr ""
#. translators: `man` command
#: cli/run.go:132
#: cli/run.go:156
msgid "man [flags]"
msgstr "manual [flags]"
@ -3694,9 +3722,8 @@ msgstr ""
#. translators: `app move` command
#: cli/app/move.go:38
#, fuzzy
msgid "move <domain> <server> [flags]"
msgstr "borrar <domain> [flags]"
msgstr "mover <domain> [flags]"
#: cli/app/move.go:137
#, c-format
@ -3716,7 +3743,7 @@ msgstr ""
#: cli/app/new.go:48 cli/recipe/new.go:36 cli/updater/updater.go:35
#: cli/updater/updater.go:513
msgid "n"
msgstr ""
msgstr "n"
#: cli/recipe/list.go:43
msgid "name"
@ -3967,11 +3994,11 @@ msgstr ""
msgid "no volumes to remove"
msgstr ""
#: cli/app/deploy.go:362 cli/app/rollback.go:344 cli/app/upgrade.go:454
#: cli/app/deploy.go:365 cli/app/rollback.go:344 cli/app/upgrade.go:454
msgid "no-converge-checks"
msgstr ""
#: cli/app/deploy.go:354 cli/app/rollback.go:336 cli/app/upgrade.go:446
#: cli/app/deploy.go:357 cli/app/rollback.go:336 cli/app/upgrade.go:446
msgid "no-domain-checks"
msgstr ""
@ -4115,7 +4142,7 @@ msgstr ""
msgid "pattern"
msgstr ""
#: cli/app/deploy.go:349 cli/app/remove.go:165 cli/app/rollback.go:331
#: cli/app/deploy.go:352 cli/app/remove.go:165 cli/app/rollback.go:331
#: cli/app/upgrade.go:441 cli/app/volume.go:219
msgid "perform action without further prompt"
msgstr ""
@ -4154,7 +4181,7 @@ msgstr ""
msgid "polling undeploy status"
msgstr "📋 Revisar el estado de una plataforma"
#: cli/run.go:185
#: cli/run.go:209
msgid "prefer offline & filesystem access"
msgstr ""
@ -4295,7 +4322,7 @@ msgid "readme: %s, "
msgstr ""
#. translators: `abra recipe` command for autocompletion
#: cli/app/list.go:302 cli/app/list.go:309 cli/run.go:76
#: cli/app/list.go:302 cli/app/list.go:309 cli/run.go:99
msgid "recipe"
msgstr ""
@ -4640,7 +4667,7 @@ msgstr ""
msgid "run command locally"
msgstr ""
#: cli/app/deploy.go:233 cli/app/upgrade.go:270
#: cli/app/deploy.go:236 cli/app/upgrade.go:270
#, c-format
msgid "run the following post-deploy commands: %s"
msgstr ""
@ -4724,7 +4751,7 @@ msgstr ""
msgid "secret not found: %s"
msgstr ""
#: cli/app/deploy.go:288
#: cli/app/deploy.go:291
#, c-format
msgid "secret not generated: %s"
msgstr ""
@ -4745,7 +4772,7 @@ msgstr ""
#. translators: `abra server` command for autocompletion
#: cli/app/list.go:325 cli/app/list.go:332 cli/app/new.go:337
#: cli/app/new.go:344 cli/run.go:78
#: cli/app/new.go:344 cli/run.go:101
msgid "server"
msgstr ""
@ -4863,7 +4890,7 @@ msgstr ""
msgid "show apps of a specific server"
msgstr ""
#: cli/run.go:169 cli/updater/updater.go:507
#: cli/run.go:193 cli/updater/updater.go:507
msgid "show debug messages"
msgstr ""
@ -4911,11 +4938,11 @@ msgstr ""
msgid "skipping converge logic checks"
msgstr ""
#: cli/app/deploy.go:186
#: cli/app/deploy.go:189
msgid "skipping domain checks"
msgstr ""
#: cli/app/deploy.go:183
#: cli/app/deploy.go:186
msgid "skipping domain checks, no DOMAIN=... configured"
msgstr ""
@ -5147,7 +5174,7 @@ msgstr ""
msgid "tmpfs options are incompatible with type volume"
msgstr ""
#: cli/run.go:177 cli/updater/updater.go:515
#: cli/run.go:201 cli/updater/updater.go:515
msgid "toggle non-interactive mode"
msgstr ""
@ -5232,7 +5259,7 @@ msgstr ""
msgid "unable to convert to JSON: %s"
msgstr ""
#: cli/run.go:94
#: cli/run.go:117
#, c-format
msgid "unable to create %s: %s"
msgstr ""
@ -5327,7 +5354,7 @@ msgstr ""
msgid "unable to parse '%s' value as bool: %s"
msgstr ""
#: cli/run.go:152
#: cli/run.go:176
#, c-format
msgid "unable to proceed, %s does not exist?"
msgstr ""
@ -5490,6 +5517,11 @@ msgstr ""
msgid "unknown deployed version, unable to upgrade"
msgstr ""
#: cli/run.go:60
#, c-format
msgid "unknown help topic %#q\n"
msgstr ""
#: pkg/upstream/convert/service.go:780
#, c-format
msgid "unknown mode: %s"
@ -5531,7 +5563,7 @@ msgid "updating %s to %s in %s"
msgstr ""
#. translators: `abra upgrade` command for autocompletion
#: cli/run.go:80
#: cli/run.go:103
msgid "upgrade"
msgstr ""
@ -5607,7 +5639,7 @@ msgstr ""
#. translators: `abra recipe versions` aliases. use a comma separated list of aliases
#. with no spaces in between
#: cli/app/backup.go:311 cli/app/restore.go:122 cli/recipe/version.go:19
#: cli/server/prune.go:107
#: cli/run.go:223 cli/server/prune.go:107
msgid "v"
msgstr ""
@ -5635,16 +5667,30 @@ msgstr ""
msgid "vendor config versions in an abra.sh"
msgstr ""
#: cli/run.go:222
msgid "version"
msgstr ""
#: pkg/app/app.go:688
#, c-format
msgid "version %s saved to %s.env"
msgstr ""
#: cli/app/deploy.go:116
#, c-format
msgid ""
"version '%s' appears to be a chaos commit, but --chaos/-C was not provided"
msgstr ""
#: pkg/recipe/recipe.go:200
#, c-format
msgid "version : %s, "
msgstr ""
#: cli/run.go:225
msgid "version for abra"
msgstr ""
#: pkg/recipe/recipe.go:130
#, c-format
msgid "version seems invalid: %s"
@ -5655,32 +5701,32 @@ msgstr ""
msgid "version wiped from %s.env"
msgstr ""
#: cli/app/deploy.go:315
#: cli/app/deploy.go:318
#, c-format
msgid "version: can not redeploy chaos version %s"
msgstr ""
#: cli/app/deploy.go:302
#: cli/app/deploy.go:305
#, c-format
msgid "version: taking chaos version: %s"
msgstr ""
#: cli/app/deploy.go:323
#: cli/app/deploy.go:326
#, c-format
msgid "version: taking deployed version: %s"
msgstr ""
#: cli/app/deploy.go:328
#: cli/app/deploy.go:331
#, c-format
msgid "version: taking new recipe version: %s"
msgstr ""
#: cli/app/deploy.go:317
#: cli/app/deploy.go:320
#, c-format
msgid "version: taking version from .env file: %s"
msgstr ""
#: cli/app/deploy.go:308
#: cli/app/deploy.go:311
#, c-format
msgid "version: taking version from cli arg: %s"
msgstr ""
@ -5806,7 +5852,7 @@ msgstr ""
msgid "writer: %v, "
msgstr ""
#: cli/app/deploy.go:240 cli/app/new.go:221 cli/app/rollback.go:232
#: cli/app/deploy.go:243 cli/app/new.go:221 cli/app/rollback.go:232
#: cli/app/undeploy.go:111 cli/app/upgrade.go:278
#, c-format
msgid "writing recipe version failed: %s"

View File

@ -174,6 +174,23 @@ teardown(){
assert_output --partial "${wantHash:0:8}"
}
# bats test_tags=slow
@test "bail if env has a hash but no --chaos" {
wantHash=$(_get_n_hash 3)
run git -C "$ABRA_DIR/recipes/$TEST_RECIPE" reset --hard HEAD~3
assert_success
assert_equal $(_get_current_hash) "$wantHash"
_ensure_env_version "$wantHash"
run $ABRA app deploy "$TEST_APP_DOMAIN" \
--no-input --no-converge-checks
assert_failure
assert_output --partial "chaos commit"
}
# bats test_tags=slow
@test "retrieve recipe if missing" {
run rm -rf "$ABRA_DIR/recipes/$TEST_RECIPE"

View File

@ -19,11 +19,18 @@ teardown_file(){
_rm_app
_rm_server
_reset_recipe
# NOTE(d1): fallback cleanup, not interested in failures here
run docker secret rm "${TEST_APP_DOMAIN}_test_pass_one_v1"
rm -rf "${BATS_TMPFILE}"
}
setup(){
load "$PWD/tests/integration/helpers/common"
_common_setup
export BATS_TMPFILE="$(mktemp)"
echo MySuperCoolPassword > ${BATS_TMPFILE}
}
teardown(){
@ -324,6 +331,41 @@ teardown(){
assert_not_exists "$ABRA_DIR/recipes/$TEST_RECIPE/foo"
}
@test "rm: dont remove all versions" {
run sed -i 's/SECRET_TEST_PASS_ONE_VERSION=v1/SECRET_TEST_PASS_ONE_VERSION=v2/g' \
"$ABRA_DIR/servers/$TEST_SERVER/$TEST_APP_DOMAIN.env"
assert_success
run $ABRA app secret generate "$TEST_APP_DOMAIN" --all
assert_success
run $ABRA app secret ls "$TEST_APP_DOMAIN"
assert_success
assert_output --partial 'test_pass_one_v2'
assert_output --partial 'true'
run docker secret create "${TEST_APP_DOMAIN}_test_pass_one_v1" "$BATS_TMPFILE"
assert_success
run docker secret ls
assert_success
assert_output --partial "${TEST_APP_DOMAIN}_test_pass_one_v1"
run $ABRA app secret rm "$TEST_APP_DOMAIN" --all
assert_success
run $ABRA app secret ls "$TEST_APP_DOMAIN"
assert_success
assert_output --partial 'false'
run docker secret ls
assert_success
assert_output --partial "${TEST_APP_DOMAIN}_test_pass_one_v1"
run docker secret rm "${TEST_APP_DOMAIN}_test_pass_one_v1"
assert_success
}
@test "ls: validate arguments" {
run $ABRA app secret ls
assert_failure

View File

@ -30,7 +30,7 @@ _ensure_catalogue(){
}
_ensure_env_version(){
run sed -i 's/TYPE=abra-test-recipe:.*/TYPE=abra-test-recipe:$1/g' \
run sed -i "s/TYPE=abra-test-recipe:.*/TYPE=abra-test-recipe:$1/g" \
"$ABRA_DIR/servers/$TEST_SERVER/$TEST_APP_DOMAIN.env"
assert_success
}