Skip to content

Commit

Permalink
Merge pull request #864 from Nordix/address_ossf_vuln
Browse files Browse the repository at this point in the history
Address ossf vuln
  • Loading branch information
efiacor authored Feb 26, 2025
2 parents c092c53 + 047ed54 commit c7cb2fe
Show file tree
Hide file tree
Showing 20 changed files with 122 additions and 94 deletions.
6 changes: 3 additions & 3 deletions krm-functions/configinject-fn/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright 2023 The Nephio Authors.
# Copyright 2023-2025 The Nephio Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -12,14 +12,14 @@
# See the License for the specific language governing permissions and
# limitations under the License.

FROM golang:1.23-alpine
FROM golang:1.23.5-alpine@sha256:sha256:47d337594bd9e667d35514b241569f95fb6d95727c24b19468813d596d5ae596
ENV CGO_ENABLED=0
WORKDIR /go/src/
COPY krm-functions/ krm-functions/
WORKDIR /go/src/krm-functions/configinject-fn
RUN go install
RUN go build -o /usr/local/bin/function ./

FROM gcr.io/distroless/static:latest
FROM gcr.io/distroless/static@sha256:3f2b64ef97bd285e36132c684e6b2ae8f2723293d09aae046196cca64251acac
COPY --from=0 /usr/local/bin/function /usr/local/bin/function
ENTRYPOINT ["function"]
6 changes: 3 additions & 3 deletions krm-functions/dnn-fn/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright 2023 The Nephio Authors.
# Copyright 2023-2025 The Nephio Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -12,14 +12,14 @@
# See the License for the specific language governing permissions and
# limitations under the License.

FROM golang:1.23-alpine
FROM golang:1.23.5-alpine@sha256:sha256:47d337594bd9e667d35514b241569f95fb6d95727c24b19468813d596d5ae596
ENV CGO_ENABLED=0
WORKDIR /go/src/
COPY krm-functions/ krm-functions/
WORKDIR /go/src/krm-functions/dnn-fn
RUN go install
RUN go build -o /usr/local/bin/function ./

FROM gcr.io/distroless/static:latest
FROM gcr.io/distroless/static@sha256:3f2b64ef97bd285e36132c684e6b2ae8f2723293d09aae046196cca64251acac
COPY --from=0 /usr/local/bin/function /usr/local/bin/function
ENTRYPOINT ["function"]
6 changes: 3 additions & 3 deletions krm-functions/gen-configmap-fn/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright 2023 The Nephio Authors.
# Copyright 2023-2025 The Nephio Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -12,14 +12,14 @@
# See the License for the specific language governing permissions and
# limitations under the License.

FROM golang:1.23-alpine
FROM golang:1.23.5-alpine@sha256:sha256:47d337594bd9e667d35514b241569f95fb6d95727c24b19468813d596d5ae596
ENV CGO_ENABLED=0
WORKDIR /go/src/
COPY krm-functions/ krm-functions/
WORKDIR /go/src/krm-functions/gen-configmap-fn
RUN go install
RUN go build -o /usr/local/bin/function ./

FROM gcr.io/distroless/static:latest
FROM gcr.io/distroless/static@sha256:3f2b64ef97bd285e36132c684e6b2ae8f2723293d09aae046196cca64251acac
COPY --from=0 /usr/local/bin/function /usr/local/bin/function
ENTRYPOINT ["function"]
2 changes: 1 addition & 1 deletion krm-functions/gen-configmap-fn/go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/nephio-project/nephio/krm-functions/gen-configmap-fn

go 1.22
go 1.23.5

replace github.com/nephio-project/nephio/krm-functions/lib => ../lib

Expand Down
4 changes: 2 additions & 2 deletions krm-functions/gen-kustomize-res/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,14 @@
# See the License for the specific language governing permissions and
# limitations under the License.

FROM golang:1.23-alpine
FROM golang:1.23.5-alpine@sha256:sha256:47d337594bd9e667d35514b241569f95fb6d95727c24b19468813d596d5ae596
ENV CGO_ENABLED=0
WORKDIR /go/src/
COPY krm-functions/ krm-functions/
WORKDIR /go/src/krm-functions/gen-kustomize-res
RUN go install
RUN go build -o /usr/local/bin/function ./

FROM gcr.io/distroless/static:latest
FROM gcr.io/distroless/static@sha256:3f2b64ef97bd285e36132c684e6b2ae8f2723293d09aae046196cca64251acac
COPY --from=0 /usr/local/bin/function /usr/local/bin/function
ENTRYPOINT ["function"]
2 changes: 1 addition & 1 deletion krm-functions/gen-kustomize-res/go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/nephio-project/nephio/krm-functions/gen-kustomize-res

go 1.22.2
go 1.23.5

require (
github.com/GoogleContainerTools/kpt-functions-sdk/go/fn v0.0.0-20230427202446-3255accc518d
Expand Down
6 changes: 3 additions & 3 deletions krm-functions/interface-fn/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright 2023 The Nephio Authors.
# Copyright 2023-2025 The Nephio Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -12,14 +12,14 @@
# See the License for the specific language governing permissions and
# limitations under the License.

FROM golang:1.23-alpine
FROM golang:1.23.5-alpine@sha256:sha256:47d337594bd9e667d35514b241569f95fb6d95727c24b19468813d596d5ae596
ENV CGO_ENABLED=0
WORKDIR /go/src/
COPY krm-functions/ krm-functions/
WORKDIR /go/src/krm-functions/interface-fn
RUN go install
RUN go build -o /usr/local/bin/function ./

FROM gcr.io/distroless/static:latest
FROM gcr.io/distroless/static@sha256:3f2b64ef97bd285e36132c684e6b2ae8f2723293d09aae046196cca64251acac
COPY --from=0 /usr/local/bin/function /usr/local/bin/function
ENTRYPOINT ["function"]
6 changes: 3 additions & 3 deletions krm-functions/ipam-fn/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright 2023 The Nephio Authors.
# Copyright 2023-2025 The Nephio Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -12,14 +12,14 @@
# See the License for the specific language governing permissions and
# limitations under the License.

FROM golang:1.23-alpine
FROM golang:1.23.5-alpine@sha256:sha256:47d337594bd9e667d35514b241569f95fb6d95727c24b19468813d596d5ae596
ENV CGO_ENABLED=0
WORKDIR /go/src/
COPY krm-functions/ krm-functions/
WORKDIR /go/src/krm-functions/ipam-fn
RUN go install
RUN go build -o /usr/local/bin/function ./

FROM gcr.io/distroless/static:latest
FROM gcr.io/distroless/static@sha256:3f2b64ef97bd285e36132c684e6b2ae8f2723293d09aae046196cca64251acac
COPY --from=0 /usr/local/bin/function /usr/local/bin/function
ENTRYPOINT ["function"]
6 changes: 3 additions & 3 deletions krm-functions/nad-fn/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright 2023 The Nephio Authors.
# Copyright 2023-2025 The Nephio Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -12,14 +12,14 @@
# See the License for the specific language governing permissions and
# limitations under the License.

FROM golang:1.23-alpine
FROM golang:1.23.5-alpine@sha256:sha256:47d337594bd9e667d35514b241569f95fb6d95727c24b19468813d596d5ae596
ENV CGO_ENABLED=0
WORKDIR /go/src/
COPY krm-functions/ krm-functions/
WORKDIR /go/src/krm-functions/nad-fn
RUN go install
RUN go build -o /usr/local/bin/function ./

FROM gcr.io/distroless/static:latest
FROM gcr.io/distroless/static@sha256:3f2b64ef97bd285e36132c684e6b2ae8f2723293d09aae046196cca64251acac
COPY --from=0 /usr/local/bin/function /usr/local/bin/function
ENTRYPOINT ["function"]
6 changes: 3 additions & 3 deletions krm-functions/nfdeploy-fn/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright 2023 The Nephio Authors.
# Copyright 2023-2025 The Nephio Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -12,14 +12,14 @@
# See the License for the specific language governing permissions and
# limitations under the License.

FROM golang:1.23-alpine
FROM golang:1.23.5-alpine@sha256:sha256:47d337594bd9e667d35514b241569f95fb6d95727c24b19468813d596d5ae596
ENV CGO_ENABLED=0
WORKDIR /go/src/
COPY krm-functions/ krm-functions/
WORKDIR /go/src/krm-functions/nfdeploy-fn
RUN go install
RUN go build -o /usr/local/bin/function ./

FROM gcr.io/distroless/static:latest
FROM gcr.io/distroless/static@sha256:3f2b64ef97bd285e36132c684e6b2ae8f2723293d09aae046196cca64251acac
COPY --from=0 /usr/local/bin/function /usr/local/bin/function
ENTRYPOINT ["function"]
6 changes: 3 additions & 3 deletions krm-functions/ueransim-deploy-fn/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright 2023 The Nephio Authors.
# Copyright 2023-2025 The Nephio Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -12,14 +12,14 @@
# See the License for the specific language governing permissions and
# limitations under the License.

FROM golang:1.23-alpine
FROM golang:1.23.5-alpine@sha256:sha256:47d337594bd9e667d35514b241569f95fb6d95727c24b19468813d596d5ae596
ENV CGO_ENABLED=0
WORKDIR /go/src/
COPY krm-functions/ krm-functions/
WORKDIR /go/src/krm-functions/ueransim-deploy-fn
RUN go install
RUN go build -o /usr/local/bin/function ./

FROM gcr.io/distroless/static:latest
FROM gcr.io/distroless/static@sha256:3f2b64ef97bd285e36132c684e6b2ae8f2723293d09aae046196cca64251acac
COPY --from=0 /usr/local/bin/function /usr/local/bin/function
ENTRYPOINT ["function"]
6 changes: 3 additions & 3 deletions krm-functions/vlan-fn/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright 2023 The Nephio Authors.
# Copyright 2023-2025 The Nephio Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -12,14 +12,14 @@
# See the License for the specific language governing permissions and
# limitations under the License.

FROM golang:1.23-alpine
FROM golang:1.23.5-alpine@sha256:sha256:47d337594bd9e667d35514b241569f95fb6d95727c24b19468813d596d5ae596
ENV CGO_ENABLED=0
WORKDIR /go/src/
COPY krm-functions/ krm-functions/
WORKDIR /go/src/krm-functions/vlan-fn
RUN go install
RUN go build -o /usr/local/bin/function ./

FROM gcr.io/distroless/static:latest
FROM gcr.io/distroless/static@sha256:3f2b64ef97bd285e36132c684e6b2ae8f2723293d09aae046196cca64251acac
COPY --from=0 /usr/local/bin/function /usr/local/bin/function
ENTRYPOINT ["function"]
4 changes: 2 additions & 2 deletions operators/focom-operator/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
# limitations under the License.

# Build the manager binary
FROM golang:1.23 AS builder
FROM golang:1.23.5@sha256:e213430692e5c31aba27473cdc84cfff2896d0c097e984bef67b6a44c75a8181 AS builder
ARG TARGETOS
ARG TARGETARCH

Expand All @@ -39,7 +39,7 @@ RUN CGO_ENABLED=0 GOOS=${TARGETOS:-linux} GOARCH=${TARGETARCH} go build -a -o ma

# Use distroless as minimal base image to package the manager binary
# Refer to https://github.com/GoogleContainerTools/distroless for more details
FROM gcr.io/distroless/static:nonroot
FROM gcr.io/distroless/static@sha256:6ec5aa99dc335666e79dc64e4a6c8b89c33a543a1967f20d360922a80dd21f02
WORKDIR /
COPY --from=builder /workspace/manager .
USER 65532:65532
Expand Down
4 changes: 2 additions & 2 deletions operators/focom-operator/config/manager/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@ apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
images:
- name: controller
newName: docker.io/nephio/focom-operator
newTag: 0.0.1
newName: nephio/focom-operator
newTag: e2e
36 changes: 18 additions & 18 deletions operators/focom-operator/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,14 @@ go 1.23.5

require (
github.com/go-logr/logr v1.4.2
github.com/onsi/ginkgo/v2 v2.21.0
github.com/onsi/gomega v1.35.1
github.com/onsi/ginkgo/v2 v2.22.2
github.com/onsi/gomega v1.36.2
github.com/stretchr/testify v1.9.0
k8s.io/api v0.32.0
k8s.io/apiextensions-apiserver v0.32.0
k8s.io/apimachinery v0.32.0
k8s.io/client-go v0.32.0
sigs.k8s.io/controller-runtime v0.20.1
k8s.io/api v0.32.2
k8s.io/apiextensions-apiserver v0.32.2
k8s.io/apimachinery v0.32.2
k8s.io/client-go v0.32.2
sigs.k8s.io/controller-runtime v0.20.2
)

require (
Expand All @@ -24,7 +24,7 @@ require (
github.com/cespare/xxhash/v2 v2.3.0 // indirect
github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect
github.com/emicklei/go-restful/v3 v3.11.0 // indirect
github.com/evanphx/json-patch/v5 v5.9.0 // indirect
github.com/evanphx/json-patch/v5 v5.9.11 // indirect
github.com/felixge/httpsnoop v1.0.4 // indirect
github.com/fsnotify/fsnotify v1.7.0 // indirect
github.com/fxamacker/cbor/v2 v2.7.0 // indirect
Expand All @@ -41,7 +41,7 @@ require (
github.com/google/gnostic-models v0.6.8 // indirect
github.com/google/go-cmp v0.6.0 // indirect
github.com/google/gofuzz v1.2.0 // indirect
github.com/google/pprof v0.0.0-20241029153458-d1b30febd7db // indirect
github.com/google/pprof v0.0.0-20241210010833-40e02aabc2ad // indirect
github.com/google/uuid v1.6.0 // indirect
github.com/grpc-ecosystem/grpc-gateway/v2 v2.20.0 // indirect
github.com/inconshreveable/mousetrap v1.1.0 // indirect
Expand Down Expand Up @@ -72,24 +72,24 @@ require (
go.uber.org/multierr v1.11.0 // indirect
go.uber.org/zap v1.27.0 // indirect
golang.org/x/exp v0.0.0-20240719175910-8a7402abbf56 // indirect
golang.org/x/net v0.30.0 // indirect
golang.org/x/net v0.35.0 // indirect
golang.org/x/oauth2 v0.23.0 // indirect
golang.org/x/sync v0.8.0 // indirect
golang.org/x/sys v0.26.0 // indirect
golang.org/x/term v0.25.0 // indirect
golang.org/x/text v0.19.0 // indirect
golang.org/x/sync v0.11.0 // indirect
golang.org/x/sys v0.30.0 // indirect
golang.org/x/term v0.29.0 // indirect
golang.org/x/text v0.22.0 // indirect
golang.org/x/time v0.7.0 // indirect
golang.org/x/tools v0.26.0 // indirect
golang.org/x/tools v0.28.0 // indirect
gomodules.xyz/jsonpatch/v2 v2.4.0 // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20240826202546-f6391c0de4c7 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20240826202546-f6391c0de4c7 // indirect
google.golang.org/grpc v1.65.0 // indirect
google.golang.org/protobuf v1.35.1 // indirect
google.golang.org/protobuf v1.36.1 // indirect
gopkg.in/evanphx/json-patch.v4 v4.12.0 // indirect
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
k8s.io/apiserver v0.32.0 // indirect
k8s.io/component-base v0.32.0 // indirect
k8s.io/apiserver v0.32.2 // indirect
k8s.io/component-base v0.32.2 // indirect
k8s.io/klog/v2 v2.130.1 // indirect
k8s.io/kube-openapi v0.0.0-20241105132330-32ad38e42d3f // indirect
k8s.io/utils v0.0.0-20241104100929-3ea5e8cea738 // indirect
Expand Down
Loading

0 comments on commit c7cb2fe

Please sign in to comment.