ldc-developers / ldc2.snap

Snap package definition for LDC, the LLVM-based D compiler
11 stars 4 forks source link

Azure Pipelines build failures #82

Open WebDrake opened 5 years ago

WebDrake commented 5 years ago

It looks like we're getting regular Azure Pipelines failures along the following lines:

+ sudo snap install --classic --candidate snapcraft
2019-06-29T16:29:19Z INFO Waiting for restart...
snapcraft (candidate) 3.6 from Canonical* installed
+ export PATH=/usr/local/cargo/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin:/snap/bin
+ PATH=/usr/local/cargo/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin:/snap/bin
+ snapcraft --version
/ not root-owned 1001:50
+ snapcraft
/ not root-owned 1001:50
##[error]Bash exited with code '1'.
##[section]Finishing: Build ldc2 snap package

Does this ring any bells with anyone?

kinke commented 5 years ago

/ not root-owned 1001:50

Their permissions in the home dir are weird, so I wouldn't be too surprised if / had a strange owner/group...

WebDrake commented 5 years ago

A ps aux | grep snapd check reveals that snapd is not owned by root, but by vsts:

+ ps aux
+ grep snapd
vsts       3989  0.0  0.0  12952   956 ?        S    21:40   0:00 grep snapd

I think this is why we're getting the message we are.

WebDrake commented 5 years ago

Hmm, that may be a red herring; it's simply the / (the CWD) in the CI system is genuinely owned by vsts (and not, as I suspect snapd expects, root). Trying to check out upstream whether snapd can be persuaded to be more tolerant when launching a new snap.

WebDrake commented 4 years ago

More recent snapcraft releases may have addressed this, and other bugs (see e.g. https://forum.snapcraft.io/t/cmake-plugin-failure-in-azure-pipelines/15825). Fingers crossed that the latest PR builds just fine in Azure Pipelines.