This changes adds logging message:debug and error. fmt.Errorf() is
wrapped by logging.Errorf() hence all error message is also put to
log file. logging.Debugf() is called at almost function call, so
we could track the code by logging message.
When multus is run inside a container, eg as a daemonset, we can use
InClusterConfig() to automatically get the service account token, the
CA certificate, and the apiserver address, all without a kubeconfig
file.
This fix removes 'masterplugin' and 'always_use_default' from
multus config file. default network, defined in
/etc/cni/net.d/*conf should be master and this network should be
used as default from network plumbing working group draft.
Change-Id: I2b35377356f2144fd3889bf5de7ac430a19edf89
Co-authored-by: Doug Smith <dougbtv@users.noreply.github.com>
Co-authored-by: Tomofumi Hayashi <s1061123@users.noreply.github.com>
Co-authored-by: Dan Williams <dcbw@users.noreply.github.com>
* Add error message for ifname collision
This changes introduce to validateIfName, to check the validation
for interface name, i.e. same name among two or more interfaces.
In case of no-config for CNIDir, multus-cni does not set
defaultCNIDir into CNIDir hence multus-cni failed to create
container network. This change fixes it.
This fix changes type type for NoK8sNetworkError due to error handling, in #45.
Currently NoK8sNetworkError is not pointer type, just a string, hence we never
get *NoK8sNetworkError. This fix changes it based @One-ders patch.
This fix changes type type for NoK8sNetworkError due to error handling, in #45.
Currently NoK8sNetworkError is not pointer type, just a string, hence we never
get *NoK8sNetworkError. This fix changes it based @One-ders patch.
bug fix for #56 & #57
Change-Id: If4f3db4dd01ca3330d5d36b8a2e4c5740def910a
Co-authored-by: Doug Smith <dougbtv@users.noreply.github.com>
Co-authored-by: Tomofumi Hayashi <s1061123@users.noreply.github.com>
Co-authored-by: Dan Williams <dcbw@users.noreply.github.com>
This change introduces go fmt/golint/go vet in CI pipeline to check
the code for each commit. In addition, this change changes code
to pass these checks.
The API endpoint wasn't exactly correct after the initial
changes to use the new namespace. Updated after a test.
Signed-off-by: dougbtv <dosmith@redhat.com>