ci / cd中断go get测试

我正在尝试预构建docker映像,以便我的ci / cd管道运行得更快,并且存在问题 </ p>

我尝试过重置缓存并更改env变量,但没有人为我工作</ p>

 获取https://git.dar。  kz / forte-market / domain?go-get = 1 
获取https://gopkg.in/olivere/elastic.v5?go-get=1
go:找到github.com/sirupsen/logrus v1.4.2
go :查找github.com/modern-go/reflect2 v1.0.1
go:查找github.com/xanzy/go-gitlab v0.20.1
go:查找github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd

go:查找github.com/tealeg/xlsx v1.0.3
go:查找github.com/gorilla/mux v1.7.3
go:查找github.com/prometheus/client_golang v1.1.0
go:查找github.com/ satori / go.uuid v1.2.0
https://gopkg.in/olivere/elastic.v5解析元标记?go-get = 1(状态码200)
获取“ gopkg.in/olivere/elastic.v5” :找到元标记get.metaImport {前缀:“ gopkg.in/olivere/elastic.v5”,VCS:“ git”,RepoR 提示:“ https://gopkg.in/olivere/elastic.v5”},网址为https://gopkg.in/olivere/elastic.v5?go-get=1
go:查找gopkg.in/olivere/elastic。 v5 v5.0.82
https://git.dar.kz/forte-market/domain解析元标记?go-get = 1(状态码200)
获取“ git.dar.kz/forte-market/domain” :找到元标记get.metaImport {前缀:“ git.dar.kz/forte-market/domain”,VCS:“ git”,RepoRoot:“ https://git.dar.kz/forte-market/domain.git https://git.dar.kz/forte-market/domain?go-get=1
go上的“}:查找git.dar.kz/forte-market/domain v1.2.0
go:git.dar.kz /forte-market/domain@v1.2.0:未知修订版v1.2.0
go:查找github.com/go-kit/kit v0.9.0
go:查找github.com/djumanoff/amqp v1.0.4
获取https: //git.dar.kz/forte-market/acl?go-get=1
解析来自https://git.dar.kz/forte-market/acl?go-get=1的元标记(状态码200)

获取“ git.dar.kz/forte-market/acl”:找到元标记get.metaImport {前缀:“ git.dar.kz/forte-market/acl”,VCS:“ git”,RepoRoot:“ https: //https://git.dar.kz/forte上的//git.dar.kz/forte-market/acl.git“} -market / acl?go-get = 1
go:查找git.dar.kz/forte-market/acl v1.0.4
go:查找github.com/sony/sonyflake v1.0.0
go:git.dar.kz /forte-market/acl@v1.0.4:未知修订版v1.0.4
go:查找github.com/caarlos0/env v3.5.0 + incompatible
go:查找github.com/gocql/gocql v0.0.0-20190829130130954-e163eff7a8c6

go:查找github.com/lestrrat-go/libxml2 v0.0.0-20190724003929-faf2a4a99869
go:加载模块要求出错
ERROR:作业失败:退出代码1
</ code> </ pre>
</ DIV>

展开原文

原文

I'm trying to prebuild docker image so that my ci/cd pipeline would go much faster and there is problem with go

I have tried reseting cache and change env variables but no one worked for me

Fetching https://git.dar.kz/forte-market/domain?go-get=1
Fetching https://gopkg.in/olivere/elastic.v5?go-get=1
go: finding github.com/sirupsen/logrus v1.4.2
go: finding github.com/modern-go/reflect2 v1.0.1
go: finding github.com/xanzy/go-gitlab v0.20.1
go: finding github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd
go: finding github.com/tealeg/xlsx v1.0.3
go: finding github.com/gorilla/mux v1.7.3
go: finding github.com/prometheus/client_golang v1.1.0
go: finding github.com/satori/go.uuid v1.2.0
Parsing meta tags from https://gopkg.in/olivere/elastic.v5?go-get=1 (status code 200)
get "gopkg.in/olivere/elastic.v5": found meta tag get.metaImport{Prefix:"gopkg.in/olivere/elastic.v5", VCS:"git", RepoRoot:"https://gopkg.in/olivere/elastic.v5"} at https://gopkg.in/olivere/elastic.v5?go-get=1
go: finding gopkg.in/olivere/elastic.v5 v5.0.82
Parsing meta tags from https://git.dar.kz/forte-market/domain?go-get=1 (status code 200)
get "git.dar.kz/forte-market/domain": found meta tag get.metaImport{Prefix:"git.dar.kz/forte-market/domain", VCS:"git", RepoRoot:"https://git.dar.kz/forte-market/domain.git"} at https://git.dar.kz/forte-market/domain?go-get=1
go: finding git.dar.kz/forte-market/domain v1.2.0
go: git.dar.kz/forte-market/domain@v1.2.0: unknown revision v1.2.0
go: finding github.com/go-kit/kit v0.9.0
go: finding github.com/djumanoff/amqp v1.0.4
Fetching https://git.dar.kz/forte-market/acl?go-get=1
Parsing meta tags from https://git.dar.kz/forte-market/acl?go-get=1 (status code 200)
get "git.dar.kz/forte-market/acl": found meta tag get.metaImport{Prefix:"git.dar.kz/forte-market/acl", VCS:"git", RepoRoot:"https://git.dar.kz/forte-market/acl.git"} at https://git.dar.kz/forte-market/acl?go-get=1
go: finding git.dar.kz/forte-market/acl v1.0.4
go: finding github.com/sony/sonyflake v1.0.0
go: git.dar.kz/forte-market/acl@v1.0.4: unknown revision v1.0.4
go: finding github.com/caarlos0/env v3.5.0+incompatible
go: finding github.com/gocql/gocql v0.0.0-20190829130954-e163eff7a8c6
go: finding github.com/lestrrat-go/libxml2 v0.0.0-20190724003929-faf2a4a99869
go: error loading module requirements
ERROR: Job failed: exit code 1

dongxiong2000
dongxiong2000 您可以发布go.mod文件,以便我们查看它尝试获取的依赖项吗?
11 个月之前 回复

2个回答



获取</ code>找不到某些软件包:</ p>

 < 代码>转到:git.dar.kz/forte-market/acl@v1.0.4:未知修订版v1.0.4 
go:git.dar.kz/forte-market/domain@v1.2.0:未知修订版v1.2.0 \ n </ code> </ pre>

您需要确保CI可以访问它们。</ p>

如果您使用的是go 1.13,请 go get </ code>尝试先从proxy.golang.org加载这些文件,然后再尝试“旧方法”。 您可以在此处了解更多信息: https://golang.org/doc/go1.13# 工具 </ p>
</ div>

展开原文

原文

go get can't find some packages:

go: git.dar.kz/forte-market/acl@v1.0.4: unknown revision v1.0.4
go: git.dar.kz/forte-market/domain@v1.2.0: unknown revision v1.2.0

You need to make sure your CI can access these.

If you're using go 1.13, go get tries to load these from proxy.golang.org first, and then "the old way". You can learn more about this here: https://golang.org/doc/go1.13#tools



问题已解决。 麻烦在docker image中的gitlab的id_rsa私钥中,因此a无法访问私有存储库。 </ p>
</ div>

展开原文

原文

problem solved. Trouble was in id_rsa private key for gitlab in docker image so that a can not access to private repositories.

Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
立即提问
相关内容推荐