Mirantis/virtlet

View on GitHub

Showing 52 of 52 total issues

Avoid deeply nested control flow statements.
Open

                        if err != nil {
                            glog.V(2).Infof("error decoding private key #%d from transport profile %s", i, rule.Transport)
                        } else {
                            privateKey = k
                        }
Severity: Major
Found in pkg/imagetranslation/translator.go - About 45 mins to fix

    Your code does not pass gofmt in 1 place. Go fmt your code!
    Open

    // +build !linux
    Severity: Minor
    Found in cmd/virtlet/pdeathsig_unsupported.go by gofmt

    type name will be used as fake.FakeDomain by other packages, and that stutters; consider calling this Domain
    Open

    type FakeDomain struct {
    Severity: Minor
    Found in pkg/virt/fake/fake_domain.go by golint

    type name will be used as fake.FakeSecret by other packages, and that stutters; consider calling this Secret
    Open

    type FakeSecret struct {
    Severity: Minor
    Found in pkg/virt/fake/fake_domain.go by golint

    method getEmulatorUidGid should be getEmulatorUIDGid
    Open

    func (fs *realFileSystem) getEmulatorUidGid() (int, int, error) {
    Severity: Minor
    Found in pkg/fs/fs.go by golint

    type name will be used as fake.FakeStoragePool by other packages, and that stutters; consider calling this StoragePool
    Open

    type FakeStoragePool struct {
    Severity: Minor
    Found in pkg/virt/fake/fake_storage.go by golint

    Your code does not pass gofmt in 1 place. Go fmt your code!
    Open

    /*
    Severity: Minor
    Found in pkg/flexvolume/flexvolume.go by gofmt

    Your code does not pass gofmt in 1 place. Go fmt your code!
    Open

    // +build linux
    Severity: Minor
    Found in pkg/fs/fs_linux.go by gofmt

    Your code does not pass gofmt in 1 place. Go fmt your code!
    Open

    // +build !linux
    Severity: Minor
    Found in pkg/utils/netns_unsupported.go by gofmt

    should replace nextToUseHostdevNo += 1 with nextToUseHostdevNo++
    Open

                        nextToUseHostdevNo += 1
    Severity: Minor
    Found in cmd/vmwrapper/vmwrapper.go by golint

    don't use ALL_CAPS in Go names; use CamelCase
    Open

        FAMILY_ALL     = netlink.FAMILY_ALL
    Severity: Minor
    Found in pkg/nettools/nettools_linux.go by golint

    don't use ALL_CAPS in Go names; use CamelCase
    Open

        FAMILY_ALL     = 0
    Severity: Minor
    Found in pkg/nettools/nettools_unsupported.go by golint

    Your code does not pass gofmt in 1 place. Go fmt your code!
    Open

    /*

    exported func NewClient returns unexported type *cni.client, which can be annoying to use
    Open

    func NewClient(pluginsDir, configsDir string) (*client, error) {
    Severity: Minor
    Found in pkg/cni/client.go by golint

    don't use ALL_CAPS in Go names; use CamelCase
    Open

        RTPROT_KERNEL  = syscall.RTPROT_KERNEL
    Severity: Minor
    Found in pkg/nettools/nettools_linux.go by golint

    exported function GenerateCert should have comment or be unexported
    Open

    func GenerateCert(t *testing.T, isCA bool, host string, signer *x509.Certificate, key *rsa.PrivateKey) (*x509.Certificate, *rsa.PrivateKey) {
    Severity: Minor
    Found in pkg/utils/testing/https.go by golint

    Your code does not pass gofmt in 1 place. Go fmt your code!
    Open

    /*
    Severity: Minor
    Found in pkg/nettools/nettools.go by gofmt

    Your code does not pass gofmt in 1 place. Go fmt your code!
    Open

    // +build !linux
    Severity: Minor
    Found in pkg/stream/utils_unsupported.go by gofmt

    Your code does not pass gofmt in 1 place. Go fmt your code!
    Open

    /*
    Severity: Minor
    Found in pkg/utils/waitproc.go by gofmt

    don't use ALL_CAPS in Go names; use CamelCase
    Open

        FAMILY_V4      = netlink.FAMILY_V4
    Severity: Minor
    Found in pkg/nettools/nettools_linux.go by golint
    Severity
    Category
    Status
    Source
    Language