containerd / containerd/nerdctl
Tests that require `not-rootless` are getting skipped with `target=docker` (where the cli is not run as root)
- Dominant language
- Go
- Stars
- 10.4k
- Forks
- 826
- Avg merge
- 1d 23h
- Merged PRs (30d)
- 44
Description
### Description
`rootlessutil.IsRootless` will (appropriately) return true if we are not root - but then, the docker daemon may run rootful, and at least some of these tests should definitely run for docker as well.
While the CI is running with `-exec sudo` - running locally without `sudo` will skip tests and give the developer the false impression it is fine.
eg:
```
go test -v ./cmd/nerdctl/container/ -run TestRunWithOOMScoreAdj -test.target docker
go test -v -exec sudo ./cmd/nerdctl/container/ -run TestRunWithOOMScoreAdj -test.target docker
```
Should likely yield the same results.
Pretty sure there are side-effects to consider here, as not being root will prevent us from writing certain files on the host for example, so, we should not change that on the legacy tooling - but we should account for that in the tooling rewrite.
### Steps to reproduce the issue
na
### Describe the results you received and expected
na
### What version of nerdctl are you using?
main
### Are you using a variant of nerdctl? (e.g., Rancher Desktop)
None
### Host information
_No response_
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.