2018-11-13 09:06:22 +01:00
|
|
|
## Development Information
|
|
|
|
|
2020-05-15 00:54:24 +09:00
|
|
|
## How to utilize multus-cni code as library?
|
|
|
|
|
|
|
|
Multus now uses [gopkg.in](http://gopkg.in/) to expose its code as library.
|
|
|
|
You can use following command to import our code into your go code.
|
|
|
|
|
|
|
|
```
|
2021-03-16 16:08:53 +09:00
|
|
|
go get gopkg.in/k8snetworkplumbingwg/multus-cni.v3
|
2020-05-15 00:54:24 +09:00
|
|
|
```
|
|
|
|
|
|
|
|
|
2020-04-29 15:26:10 -04:00
|
|
|
## How do I submit an issue?
|
|
|
|
|
|
|
|
Use GitHub as normally, you'll be presented with an option to submit a issue or enhancement request.
|
|
|
|
|
|
|
|
Issues are considered stale after 90 days. After which, the maintainers reserve the right to close an issue.
|
|
|
|
|
|
|
|
Typically, we'll tag the submitter and ask for more information if necessary before closing.
|
|
|
|
|
|
|
|
If an issue is closed that you don't feel is sufficiently resolved, please feel free to re-open the issue and provide any necessary information.
|
|
|
|
|
|
|
|
## How do I build multus-cni?
|
|
|
|
|
2020-05-28 16:43:59 -04:00
|
|
|
You can use the built in `./hack/build-go.sh` script!
|
2018-11-13 09:06:22 +01:00
|
|
|
|
|
|
|
```
|
2021-03-16 16:08:53 +09:00
|
|
|
git clone https://github.com/k8snetworkplumbingwg/multus-cni.git
|
2018-11-13 09:06:22 +01:00
|
|
|
cd multus-cni
|
2020-05-28 16:43:59 -04:00
|
|
|
./hack/build-go.sh
|
2018-11-13 09:06:22 +01:00
|
|
|
```
|
|
|
|
|
2020-04-29 15:26:10 -04:00
|
|
|
## How do I run CI tests?
|
2018-11-13 09:06:22 +01:00
|
|
|
|
2019-09-19 21:57:49 -04:00
|
|
|
Multus has go unit tests (based on ginkgo framework).The following commands drive CI tests manually in your environment:
|
2018-11-13 09:06:22 +01:00
|
|
|
|
|
|
|
```
|
2022-01-14 10:59:29 -05:00
|
|
|
sudo ./hack/test-go.sh
|
2018-11-13 09:06:22 +01:00
|
|
|
```
|
|
|
|
|
2020-04-29 15:26:10 -04:00
|
|
|
## What are the best practices for logging?
|
2018-11-13 09:06:22 +01:00
|
|
|
|
2020-04-29 15:26:10 -04:00
|
|
|
The following are the best practices for multus logging:
|
2018-11-13 09:06:22 +01:00
|
|
|
|
2021-09-10 20:50:23 +08:00
|
|
|
* Add `logging.Debugf()` at the beginning of functions
|
2018-11-13 09:06:22 +01:00
|
|
|
* In case of error handling, use `logging.Errorf()` with given error info
|
2019-09-19 21:29:02 -04:00
|
|
|
* `logging.Panicf()` only be used for critical errors (it should NOT normally be used)
|
2018-11-13 09:06:22 +01:00
|
|
|
|
|
|
|
|
2021-03-18 10:11:23 -04:00
|
|
|
## Multus release schedule
|
2018-11-13 09:06:22 +01:00
|
|
|
|
2021-03-18 10:11:23 -04:00
|
|
|
On the first maintainer's meeting, twice yearly, after January 1st and July 1st, if a new version has not been tagged, a new version will tagged.
|