diff --git a/.github/workflows/build-latest-image.yml b/.github/workflows/build-latest-image.yml index 9b815ec..93f48d7 100644 --- a/.github/workflows/build-latest-image.yml +++ b/.github/workflows/build-latest-image.yml @@ -65,7 +65,7 @@ jobs: ref: ${{ github.sha }} - name: Authenticate against Quay.io - if: ${{ github.ref == 'refs/heads/main' && github.repository_owner == 'test-network-function' }} + if: ${{ github.ref == 'refs/heads/main' && github.repository_owner == 'redhat-best-practices-for-k8s' }} uses: docker/login-action@v3 with: registry: ${{ env.REGISTRY }} @@ -75,5 +75,5 @@ jobs: password: ${{ secrets.QUAY_ROBOT_TOKEN }} - name: Build and push image - if: ${{ github.ref == 'refs/heads/main' && github.repository_owner == 'test-network-function' }} + if: ${{ github.ref == 'refs/heads/main' && github.repository_owner == 'redhat-best-practices-for-k8s' }} run: ./scripts/image.sh diff --git a/go.mod b/go.mod index 88ffa11..69867d1 100644 --- a/go.mod +++ b/go.mod @@ -1,10 +1,10 @@ -module github.com/test-network-function/l2discovery +module github.com/redhat-best-practices-for-k8s/l2discovery go 1.21.4 require github.com/sirupsen/logrus v1.9.3 require ( - github.com/test-network-function/l2discovery-exports v0.0.3 + github.com/redhat-best-practices-for-k8s/l2discovery-exports v0.0.4 golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8 // indirect ) diff --git a/go.sum b/go.sum index 156447e..b1acc23 100644 --- a/go.sum +++ b/go.sum @@ -3,13 +3,13 @@ github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= +github.com/redhat-best-practices-for-k8s/l2discovery-exports v0.0.4 h1:66qE0Vj/8vWvt8yaVq1yJK5+OOELGZdlCwzHkXRxFr4= +github.com/redhat-best-practices-for-k8s/l2discovery-exports v0.0.4/go.mod h1:NO9mpaj5neVKarRGcsL5SHVFb+uYUoCC8uVbuT419xs= github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ= github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -github.com/test-network-function/l2discovery-exports v0.0.3 h1:kuzpWu5UQL3VIG+8AkjmsghkjZN1X3k3dQ8M36DsJc4= -github.com/test-network-function/l2discovery-exports v0.0.3/go.mod h1:38JgpFHXB9PQ+4bPZQ+STsUKK9BrTe+5uDq47OeMV50= golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8 h1:0A+M6Uqn+Eje4kHMK80dtF3JCXC4ykBgQG4Fe06QRhQ= golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= diff --git a/l2discovery.go b/l2discovery.go index 7a84c3d..6eb35c8 100644 --- a/l2discovery.go +++ b/l2discovery.go @@ -14,8 +14,8 @@ import ( "time" "unsafe" + exports "github.com/redhat-best-practices-for-k8s/l2discovery-exports" "github.com/sirupsen/logrus" - exports "github.com/test-network-function/l2discovery-exports" ) /* @@ -321,7 +321,8 @@ func getIfs() (macs map[string]*exports.Iface, macsExist map[string]bool, err er macs = make(map[string]*exports.Iface) macsExist = make(map[string]bool) aIPOut := []*ipOut{} - if err := json.Unmarshal([]byte(stdout), &aIPOut); err != nil { + err = json.Unmarshal([]byte(stdout), &aIPOut) + if err != nil { return macs, macsExist, err } for _, aIfRaw := range aIPOut {