Contributing to sxlimits
In order to contribute to the project, please follow this procedure.
0. Requirements
- Having a RedHat-like (Fedora, CentOS, RHEL, …) operating system
- Install git:
sudo yum install git - Install Go:
sudo yum install go(or from go.dev/dl) - Install a Kubernetes client:
- OpenShift client:
sudo yum install openshift-client - Kubernetes client:
sudo yum install kubectl - Have a fork of the project on your GitLab account (see GitLab fork documentation)
1. Get a copy of the repository
Fork the upstream repository to your GitLab account, then clone your fork locally:
# Clone your fork (replace <your-username> with your GitLab username)
git clone git@gitlab.com:<your-username>/sxlimits.git
cd sxlimits
# Add the upstream project as a remote to stay in sync
git remote add upstream git@gitlab.com:startx1/k8s/sxlimits.git
# Switch to the devel branch and create your feature branch
git checkout devel
git checkout -b devel-myfeature
2. Generate the binary
Build the sxlimits binary from source and verify the build is clean:
make build
3. Test your binary
Execute a quick smoke test to confirm the binary runs correctly:
./bin/sxlimits version
4. Make your changes
Implement your feature or fix. Rebuild and test after each significant change:
make build
./bin/sxlimits list
Run the full test suite to ensure nothing is broken:
make release
5. Publish your changes
Push your changes to your fork’s feature branch. The CI pipeline on your fork will validate the build and run the tests automatically.
git add .
git commit -m "describe your change clearly"
git push origin devel-myfeature
Check that the CI pipeline passes on your fork at https://gitlab.com/<your-username>/sxlimits/-/pipelines before proceeding.
6. Create a merge request
Once your changes are validated on your fork, follow the steps below to submit a merge request to the upstream project.
6.1 Create a tag on your fork
Create a tag on your fork’s devel-myfeature branch to trigger the full build pipeline and produce verifiable artifacts:
# Tag your contribution (use a version that identifies your contribution)
git tag v0.x.y-myfeature
git push origin v0.x.y-myfeature
Verify that the tagged pipeline completes successfully on your fork at https://gitlab.com/<your-username>/sxlimits/-/pipelines.
6.2 Open a merge request on GitLab
Go to your fork on GitLab and open a merge request targeting the upstream devel branch:
- Navigate to
https://gitlab.com/<your-username>/sxlimits/-/merge_requests/new - Source branch:
<your-username>/sxlimits:devel-myfeature - Target branch:
startx1/k8s/sxlimits:devel
6.3 Fill in the merge request description
Provide a clear and complete description including:
- Summary: what the change does and why
- Linked work item: reference the feature or bug work item (e.g.
Closes #42) - Tests done: describe how you tested the change (unit tests, integration tests, manual steps)
- Breaking changes: list any breaking API or behaviour changes
- Artifacts: link to the successful tagged pipeline on your fork
6.4 Wait for review
A maintainer will review your merge request. Be responsive to feedback and update your branch as needed. Once approved, the maintainer will merge your changes into devel.