Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 34 additions & 0 deletions .github/workflows/fork-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# 2025 NVIDIA CORPORATION & AFFILIATES
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
name: Fork Release CI

on:
push:
branches:
- network-operator-*
tags:
- network-operator-*

jobs:
call-reusable-ci-fork-workflow:
uses: Mellanox/cloud-orchestration-reusable-workflows/.github/workflows/fork-ci-reusable.yml@main
with:
registry-internal: nvcr.io/nvstaging/mellanox
service-account-username: nvidia-ci-cd
service-account-email: [email protected]
components: '[{"name": "SriovDevicePlugin", "imageName": "sriov-network-device-plugin", "Dockerfile": "images/Dockerfile.nvidia"}]'
secrets:
registry-username: ${{ secrets.NVCR_USERNAME }}
registry-token: ${{ secrets.NVCR_TOKEN }}
cicd-gh-token: ${{ secrets.GH_TOKEN_NVIDIA_CI_CD }}
28 changes: 28 additions & 0 deletions .github/workflows/fork-sync.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# 2025 NVIDIA CORPORATION & AFFILIATES
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
name: Fork Sync

on:
schedule:
- cron: '0 0 * * *' # nightly
workflow_dispatch: # enable manual trigger

jobs:
call-reusable-sync-fork-workflow:
uses: Mellanox/cloud-orchestration-reusable-workflows/.github/workflows/fork-sync-reusable.yml@main
with:
upstream-owner: k8snetworkplumbingwg
default-branch: master
secrets:
gh_token: ${{ secrets.GITHUB_TOKEN }}
46 changes: 46 additions & 0 deletions images/Dockerfile.nvidia
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
# Copyright 2025 sriov-network-device-plugin Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

FROM --platform=$BUILDPLATFORM golang:1.23.4 AS builder
ARG TARGETPLATFORM
ARG TARGETARCH
ARG TARGETVARIANT
ARG GCFLAGS

ADD . /usr/src/sriov-network-device-plugin

ENV HTTP_PROXY $http_proxy
ENV HTTPS_PROXY $https_proxy
RUN apt-get update && \
apt-get install -y build-essential linux-headers-generic make && \
cd /usr/src/sriov-network-device-plugin && \
GOOS=linux GOARCH=${TARGETARCH} GOARM=${TARGETVARIANT} make clean && \
GOOS=linux GOARCH=${TARGETARCH} GOARM=${TARGETVARIANT} make build

FROM nvcr.io/nvidia/doca/doca:3.0.0-base-rt-host

ARG TARGETPLATFORM
ARG TARGETARCH
ARG TARGETVARIANT

COPY --from=builder /usr/src/sriov-network-device-plugin/build/sriovdp /usr/bin/
WORKDIR /

COPY --from=builder /usr/src/sriov-network-device-plugin ./src

LABEL io.k8s.display-name="SRIOV Network Device Plugin"

ADD ./images/entrypoint.sh /

ENTRYPOINT ["/entrypoint.sh"]
Loading