Skip to content

Commit 7e3b83a

Browse files
ngopalak-redhatk8s-ci-robot
authored andcommitted
Doc updates for developers of SPO
1 parent ed66f8e commit 7e3b83a

File tree

1 file changed

+29
-0
lines changed

1 file changed

+29
-0
lines changed

hacking.md

+29
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ There are currently two optional features at build time
1616
- eBPF based recording
1717
- This feature requires a rather new `libbpf` which requires a new `libelf`
1818
version which in turn requires a new `libz` version.
19+
- Install the necessary libraries based on your build OS.
20+
For example, on Fedora, you'll need to install the RPMs `elfutils-libelf-devel` and `libbpf-devel`
1921
- disable with `BPF_ENABLED=0`
2022
- AppArmor
2123
- This feature requires apparmor headers and development libraries as well as the `go-apparmor` bindings
@@ -35,6 +37,8 @@ for actually deploying the operator, `libseccomp` is not optional and whether
3537
to build against seccomp is determined automatically based on the build
3638
platform.
3739

40+
Also make sure you have `clang-tools-extra` installed
41+
3842
To build SPO with all the features simply run:
3943
```shell
4044
make
@@ -44,6 +48,31 @@ To disable features, prefix `make` with environment variables that deselect them
4448
BPF_ENABLED=0 APPARMOR_ENABLED=0 make
4549
```
4650

51+
In most cases you will need a container image. You can build by running:
52+
```shell
53+
make image
54+
```
55+
56+
## Submitting a Pull Request (PR)
57+
58+
Here's the process for contributing your changes:
59+
60+
1. **Fork and Branch:**
61+
* First, create your own copy (a "fork") of the [main repository](https://github.com/kubernetes-sigs/security-profiles-operator) on GitHub.
62+
* Then, create a new branch within your forked repository to work on your changes.
63+
64+
2. **Build and Test:**
65+
* Build a container image of your changes. This ensures your code runs in a kubernetes environment (Ex: OpenShift).
66+
67+
3. **Verify:**
68+
* Run the command `make verify`. This command executes automated checks (like code style) to ensure your changes meet the project's standards. Make sure this command passes without any errors.
69+
70+
4. **PR Description:**
71+
* When you create your Pull Request to merge your changes back into the main repository, please provide a clear description.
72+
* Specifically, make sure to clearly indicate:
73+
* **Type of PR:** What kind of change is this?
74+
* **User-facing change:** If your changes will be noticeable to users of the project, briefly explain what those changes are. If not, you can state "NONE"
75+
4776
## Running unit tests and viewing coverage
4877
SPO uses the Go's `testing` library augmented with [testify](https://github.com/stretchr/testify)
4978
to provide nicer assertions and [counterfeiter](https://github.com/maxbrunsfeld/counterfeiter)

0 commit comments

Comments
 (0)