Git fails to describe project in build server
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
launchpad-buildd |
Triaged
|
High
|
Unassigned |
Bug Description
I'm trying to `snapcraft remote-build` the Charmcraft snap, which calculates the version doing `git describe --tags --dirty`.
However, that command fails on the servers.
FTR, the project uploaded by Snapcraft has the proper tags in it, this is the output I get if I tweak the project to do `git log`:
```
commit b22fcdba3b89400
```
(full output of the command: https:/
The problem is that Git is failing with:
```
fatal: detected dubious ownership in repository at '/build/
To add an exception for this directory, call:
git config --global --add safe.directory /build/
```
Which is weird, because everything looks owned by `root`: the following is the result of running `id` instead of `git` in the server:
uid=0(root) gid=0(root) groups=0(root)
...and attached in this report is the whole output of `find /build -ls`.
The Git version in the servers is:
```
git version 2.25.1
cpu: x86_64
no commit associated with this build
sizeof-long: 8
sizeof-size_t: 8
```
Thanks!
Changed in launchpad-buildd: | |
status: | New → Triaged |
importance: | Undecided → High |
tags: | added: lp-code |