From dea7ae27a9dfdf5e0ed9c46781a561b40a979e04 Mon Sep 17 00:00:00 2001 From: Mete Durlu Date: Fri, 4 Feb 2022 12:53:25 +0100 Subject: [PATCH] Add instructions on using go with admin perms For testing and possibly other operations go might need elevated permissions. Some parts of documentation and the BUILDING.md mention using `sudo go` but does not explain how to achieve this. This commit inserts instructions to the BUILDING.md as a small note. Note mentions systemwide and local solutions. Signed-off-by: Mete Durlu --- BUILDING.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/BUILDING.md b/BUILDING.md index 0174cd576..5310924ce 100644 --- a/BUILDING.md +++ b/BUILDING.md @@ -260,6 +260,10 @@ PASS ok github.com/containerd/containerd 4.778s ``` +> *Note*: in order to run `sudo go` you need to +> - either keep user PATH environment variable. ex: `sudo "PATH=$PATH" env go test ` +> - or use `go test -exec` ex: `go test -exec sudo -v -run "TestTarWithXattr" ./archive/ -test.root` + ## Additional tools ### containerd-stress