juicedata / juicesync

A tool to move your data between any clouds or regions.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

aws bucket name 包含点就无法同步

SecretSun opened this issue · comments

object/s3.go
212 hostParts := strings.SplitN(uri.Host, ".", 2)
这样写的话 bucket name 中包含点 就 GG 了
麻烦 Fix

如下是我自己修改的

	hostParts := strings.SplitN(uri.Host, ".s3.", 2)
	bucket := hostParts[0]
	endpoint = hostParts[1]
        endpoint = "s3." + endpoint

能给个例子吗?bucket name 应该不能包含 "." 的

能给个例子吗?bucket name 应该不能包含 "." 的

比如
s3 bucket name 为 a.b.c
那么我们就会输入 s3://a.b.c.s3.cn-north-1.amazonaws.com.cn
但是呢 我们发现 最终 去 list 的时候 回去读
s3://a 接着这个肯定是会报错的

Fixed by #30