Skip to content

Commit bb4fa55

Browse files
authored
Merge pull request #5443 from randomvariable/selinux-dev-note
📖 Add note about SELinux issues in image building
2 parents 461ea3f + 5bb2313 commit bb4fa55

File tree

1 file changed

+13
-4
lines changed

1 file changed

+13
-4
lines changed

docs/book/src/developer/testing.md

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -90,20 +90,20 @@ GINKGO_FOCUS="\[PR-Blocking\]" ./scripts/ci-e2e.sh
9090
### Test execution via make test-e2e
9191

9292
`make test-e2e` will run e2e tests by using whatever provider images already exist on disk.
93-
After running `make docker-build-e2e` at least once, `make test-e2e` can be used for a faster test run, if there are no
93+
After running `make docker-build-e2e` at least once, `make test-e2e` can be used for a faster test run, if there are no
9494
provider code changes. If the provider code is changed, run `make docker-build-e2e` to update the images.
9595

9696
### Test execution via IDE
9797

9898
It's also possible to run the tests via an IDE which makes it easier to debug the test code by stepping through the code.
9999

100-
First, we have to make sure all prerequisites are fulfilled, i.e. all required images have been built (this also includes
100+
First, we have to make sure all prerequisites are fulfilled, i.e. all required images have been built (this also includes
101101
kind images). This can be done by executing the `./scripts/ci-e2e.sh` script.
102102

103103
```bash
104104
# Notes:
105105
# * You can cancel the script as soon as it starts the actual test execution via `make -C test/e2e/ run`.
106-
# * If you want to run other tests (e.g. upgrade tests), make sure all required env variables are set (see the Prow Job config).
106+
# * If you want to run other tests (e.g. upgrade tests), make sure all required env variables are set (see the Prow Job config).
107107
GINKGO_FOCUS="\[PR-Blocking\]" ./scripts/ci-e2e.sh
108108

109109
# Make sure the cluster-templates have been generated.
@@ -114,7 +114,7 @@ Now, the tests can be run in an IDE. The following describes how this can be don
114114
roughly the same way in all other IDEs. We assume the `cluster-api` repository has been checked
115115
out into `/home/user/code/src/sigs.k8s.io/cluster-api`.
116116

117-
#### Intellij
117+
#### Intellij
118118

119119
Create a new run configuration and fill in:
120120
* Test framework: `gotest`
@@ -193,6 +193,15 @@ The following env variables can be set to customize the test execution:
193193

194194
Furthermore, it's possible to overwrite all env variables specified in `variables` in `test/e2e/config/docker.yaml`.
195195

196+
### Known Issues
197+
198+
#### Building images on SELinux
199+
200+
Cluster API repositories use [Moby Buildkit](https://github.com/moby/buildkit) to speed up image builds.
201+
[BuildKit does not currently work on SELinux](https://github.com/moby/buildkit/issues/2295).
202+
203+
Use `sudo setenforce 0` to make SELinux permissive when running e2e tests.
204+
196205
## Quick reference
197206

198207
### `envtest`

0 commit comments

Comments
 (0)