Skip to content

Commit 4973687

Browse files
committed
chore(volumes): add path_style for oss
1 parent 52ace12 commit 4973687

4 files changed

Lines changed: 22 additions & 7 deletions

File tree

internal/parser/volumes.go

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ func volumesAddCommand(cmdr *commands.DryccCmd) *cobra.Command {
4545
nfsPath string
4646
ossServer string
4747
ossBucket string
48+
ossPathStyle bool
4849
ossAccessKey string
4950
ossSecretKey string
5051
}
@@ -76,6 +77,7 @@ func volumesAddCommand(cmdr *commands.DryccCmd) *cobra.Command {
7677
"bucket": flags.ossBucket,
7778
"access_key": flags.ossAccessKey,
7879
"secret_key": flags.ossSecretKey,
80+
"path_style": flags.ossPathStyle,
7981
}
8082
}
8183
return cmdr.VolumesCreate(app, flags.name, flags.vtype, flags.size, parameters)
@@ -89,7 +91,8 @@ func volumesAddCommand(cmdr *commands.DryccCmd) *cobra.Command {
8991
cmd.Flags().StringVar(&flags.ossServer, "oss-server", "", i18n.T("Endpoint url for object storage service"))
9092
cmd.Flags().StringVar(&flags.ossBucket, "oss-bucket", "", i18n.T("Bucket name in object storage"))
9193
cmd.Flags().StringVar(&flags.ossAccessKey, "oss-access-key", "", i18n.T("Access key id for authentication"))
92-
cmd.Flags().StringVar(&flags.ossSecretKey, "oss-secret-key", "", i18n.T("secret access key for authentication"))
94+
cmd.Flags().StringVar(&flags.ossSecretKey, "oss-secret-key", "", i18n.T("Secret access key for authentication"))
95+
cmd.Flags().BoolVar(&flags.ossPathStyle, "oss-path-style", false, i18n.T("Force a path-style endpoint to be used"))
9396

9497
cmd.Flags().SortFlags = false
9598
cmd.MarkFlagsRequiredTogether("nfs-server", "nfs-path")

pkg/i18n/translations/drycc/en_US/LC_MESSAGES/cli.po

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1704,8 +1704,12 @@ msgid ""
17041704
" only single extra service per Porcfile type could be created."
17051705
msgstr ""
17061706

1707-
#: internal/parser/volumes.go:91
1708-
msgid "secret access key for authentication"
1707+
#: internal/parser/volumes.go:95
1708+
msgid "Secret access key for authentication"
1709+
msgstr ""
1710+
1711+
#: internal/parser/volumes.go:97
1712+
msgid "Force a path-style endpoint to be used"
17091713
msgstr ""
17101714

17111715
#: internal/parser/resources.go:224

pkg/i18n/translations/drycc/template.pot

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1697,8 +1697,12 @@ msgid ""
16971697
" only single extra service per Porcfile type could be created."
16981698
msgstr ""
16991699

1700-
#: internal/parser/volumes.go:91
1701-
msgid "secret access key for authentication"
1700+
#: internal/parser/volumes.go:95
1701+
msgid "Secret access key for authentication"
1702+
msgstr ""
1703+
1704+
#: internal/parser/volumes.go:97
1705+
msgid "Force a path-style endpoint to be used"
17021706
msgstr ""
17031707

17041708
#: internal/parser/resources.go:224

pkg/i18n/translations/drycc/zh_CN/LC_MESSAGES/cli.po

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1783,10 +1783,14 @@ msgstr ""
17831783
"要处理请求的Procfile类型(如webhooks),需绑定到PORT端口\n"
17841784
" 每个Procfile类型只能创建一个附加服务"
17851785

1786-
#: internal/parser/volumes.go:91
1787-
msgid "secret access key for authentication"
1786+
#: internal/parser/volumes.go:95
1787+
msgid "Secret access key for authentication"
17881788
msgstr "认证密钥(Secret Access Key)"
17891789

1790+
#: internal/parser/volumes.go:97
1791+
msgid "Force a path-style endpoint to be used"
1792+
msgstr "强制使用路径风格的端点"
1793+
17901794
#: internal/parser/resources.go:224
17911795
msgid ""
17921796
"skips the prompt for the resource name. <resource> is the uniquely "

0 commit comments

Comments
 (0)