admin管理员组

文章数量:1336175

I am in a disconnected environment and am hosting the bazel-central-registry in a gitlab repo. I am trying to specify the registry in my .bazelrc file. I can get it to work with a local file system path:

build --registry=file:///D:/repos/bazel-central-registry

But when I use the gitlab repo as the registry I get errors that bazel can't parse metadata.json. Is this the correct way to reference the gitlab repo? Examples I have seen use raw url on github, but I haven't found an example using gitlab repo...

build --registry=/my_group/bazel-central-registry/-/tree/dev

I am in a disconnected environment and am hosting the bazel-central-registry in a gitlab repo. I am trying to specify the registry in my .bazelrc file. I can get it to work with a local file system path:

build --registry=file:///D:/repos/bazel-central-registry

But when I use the gitlab repo as the registry I get errors that bazel can't parse metadata.json. Is this the correct way to reference the gitlab repo? Examples I have seen use raw url on github, but I haven't found an example using gitlab repo...

build --registry=http://my.gitlab/my_group/bazel-central-registry/-/tree/dev

Share edited Nov 19, 2024 at 19:45 Eric Stoces asked Nov 19, 2024 at 19:44 Eric StocesEric Stoces 12 bronze badges 1
  • This worked, although the url in the browser returns a 404. build --registry=http://my.gitlab/my_group/bazel-central-registry/raw/dev – Eric Stoces Commented Nov 19, 2024 at 20:43
Add a comment  | 

1 Answer 1

Reset to default 0

This worked, although the url in the browser returns a 404.

bazel build //example:hello-world --registry=http://my.gitlab/my_group/bazel-central-registry/raw/dev

本文标签: BazelCentralRegistry Hosted in GitlabStack Overflow