From 6865288cf11eeca22c2b2853f10d26c41c399f51 Mon Sep 17 00:00:00 2001 From: l-technicore Date: Tue, 19 Nov 2024 19:58:02 +0530 Subject: [PATCH] Fixes --- .github/workflows/makefile.yml | 11 +++++++---- .github/workflows/release.yaml | 4 ++-- Dockerfile | 4 ++-- Dockerfile_arm_all | 6 +++--- 4 files changed, 14 insertions(+), 11 deletions(-) diff --git a/.github/workflows/makefile.yml b/.github/workflows/makefile.yml index ad30f6ef3c..2456ce7cd0 100644 --- a/.github/workflows/makefile.yml +++ b/.github/workflows/makefile.yml @@ -12,18 +12,21 @@ jobs: - name: Set up Go 1.x uses: actions/setup-go@v2 with: - go-version: '1.20' + go-version: '1.22.9' id: go - name: Check out code into the Go module directory uses: actions/checkout@v2 - + - name: Install dependencies + run: | + go mod download - name: Run Unit Tests run: | go test -covermode=count -coverprofile=profile.cov ./pkg/... + - name: Install goveralls + run: go install github.com/mattn/goveralls@latest - name: Send coverage env: COVERALLS_TOKEN: ${{ secrets.GITHUB_TOKEN }} run: | - GO111MODULE=off go get github.com/mattn/goveralls - $(go env GOPATH)/bin/goveralls -coverprofile=profile.cov -service=github + goveralls -coverprofile=profile.cov -service=github diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 56591c42cb..83e9193969 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -26,7 +26,7 @@ jobs: run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u ${GITHUB_ACTOR,,} --password-stdin - name: Build Image - run: OSS_REGISTRY="ghcr.io/oracle" VERSION="${{ github.ref_name }}" make image + run: OSS_REGISTRY="ghcr.io/${GITHUB_ACTOR,,}" VERSION="${{ github.ref_name }}" make image - name: Push Image - run: OSS_REGISTRY="ghcr.io/oracle" VERSION="${{ github.ref_name }}" make docker-push-all + run: OSS_REGISTRY="ghcr.io/${GITHUB_ACTOR,,}" VERSION="${{ github.ref_name }}" make docker-push-all diff --git a/Dockerfile b/Dockerfile index ccd55996aa..56ee3d789e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -14,7 +14,7 @@ ARG CI_IMAGE_REGISTRY -FROM golang:1.22.8 as builder +FROM golang:1.22.9 as builder ARG COMPONENT @@ -27,7 +27,7 @@ WORKDIR $SRC RUN COMPONENT=${COMPONENT} make clean build -FROM oraclelinux:8-slim +FROM ghcr.io/oracle/oraclelinux:8-slim-fips COPY --from=0 /go/src/github.com/oracle/oci-cloud-controller-manager/dist/* /usr/local/bin/ COPY --from=0 /go/src/github.com/oracle/oci-cloud-controller-manager/image/* /usr/local/bin/ diff --git a/Dockerfile_arm_all b/Dockerfile_arm_all index 1bdf8f9cf8..2b5feb4006 100644 --- a/Dockerfile_arm_all +++ b/Dockerfile_arm_all @@ -1,6 +1,6 @@ ARG CI_IMAGE_REGISTRY -FROM golang:1.21.5 as builder +FROM golang:1.22.9 as builder ARG COMPONENT @@ -14,7 +14,7 @@ WORKDIR $SRC RUN ARCH=arm make clean build-arm-all -FROM arm64v8/oraclelinux:8-slim +FROM ghcr.io/oracle/oraclelinux:8-slim-fips-arm64v8 RUN microdnf -y install util-linux e2fsprogs xfsprogs python2 && \ microdnf update && \ @@ -29,4 +29,4 @@ RUN chmod 755 /sbin/encrypt-umount RUN chmod 755 /sbin/rpm-host RUN chmod 755 /sbin/chroot-bash -COPY --from=0 /go/src/github.com/oracle/oci-cloud-controller-manager/dist/arm/* /usr/local/bin/ \ No newline at end of file +COPY --from=0 /go/src/github.com/oracle/oci-cloud-controller-manager/dist/arm/* /usr/local/bin/