Skip to content

Commit 680b5d8

Browse files
Update cloud-proivder-powervs commit (#2335)
Signed-off-by: Prajyot-Parab <[email protected]>
1 parent fcaaad0 commit 680b5d8

File tree

2 files changed

+18
-3
lines changed

2 files changed

+18
-3
lines changed

hack/ccm/Makefile

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,10 @@ REGISTRY=gcr.io/k8s-staging-capi-ibmcloud
2020
IMG=powervs-cloud-controller-manager
2121

2222
# POWERVS_CLOUD_CONTROLLER_COMMIT can be fetched from here https://github.com/openshift/cloud-provider-powervs/commits/main
23-
POWERVS_CLOUD_CONTROLLER_COMMIT?=7c51cd2
23+
POWERVS_CLOUD_CONTROLLER_COMMIT?=ef83f3f
2424
TAG?=$(POWERVS_CLOUD_CONTROLLER_COMMIT)
2525

26-
build-image: init-buildx
26+
build-image: init-buildx gcloud-auth
2727
{ \
2828
set -e ; \
2929
docker buildx build \
@@ -38,6 +38,18 @@ init-buildx:
3838
-docker buildx rm multiarch-multiplatform-builder
3939
docker buildx create --use --name=multiarch-multiplatform-builder
4040
docker run --rm --privileged multiarch/qemu-user-static --reset --credential yes --persistent yes
41+
42+
gcloud-auth:
4143
# Register gcloud as a Docker credential helper.
4244
# Required for "docker buildx build --push".
4345
gcloud auth configure-docker --quiet
46+
47+
build-local: init-buildx
48+
{ \
49+
set -e ; \
50+
docker buildx build \
51+
--platform=linux/$(ARCH) --pull \
52+
--build-arg golang_image=$(GO_CONTAINER_IMAGE) \
53+
--build-arg POWERVS_CLOUD_CONTROLLER_COMMIT=$(POWERVS_CLOUD_CONTROLLER_COMMIT) \
54+
-t $(REGISTRY)/$(IMG)-$(ARCH):$(TAG) . --output=type=docker --target centos-base; \
55+
}

hack/verify-container-images.sh

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,15 +34,18 @@ TRIVY="${REPO_ROOT}/hack/tools/bin/trivy/${VERSION}/trivy"
3434
make REGISTRY=gcr.io/k8s-staging-capi-ibmcloud PULL_POLICY=IfNotPresent TAG=dev OUTPUT_TYPE=type=docker docker-build
3535
make clean-release-git
3636

37+
make -C hack/ccm ARCH="${GO_ARCH}" TAG=dev build-local
38+
3739
# Scan the images
3840
"${TRIVY}" image -q --exit-code 1 --ignore-unfixed --severity MEDIUM,HIGH,CRITICAL gcr.io/k8s-staging-capi-ibmcloud/cluster-api-ibmcloud-controller-"${GO_ARCH}":dev && R1=$? || R1=$?
41+
"${TRIVY}" image -q --exit-code 1 --ignore-unfixed --severity MEDIUM,HIGH,CRITICAL gcr.io/k8s-staging-capi-ibmcloud/powervs-cloud-controller-manager-"${GO_ARCH}":dev && R2=$? || R2=$?
3942

4043
echo ""
4144
BRed='\033[1;31m'
4245
BGreen='\033[1;32m'
4346
NC='\033[0m' # No
4447

45-
if [ "$R1" -ne "0" ]
48+
if [ "$R1" -ne "0" ] || [ "$R2" -ne "0" ]
4649
then
4750
echo -e "${BRed}Check container images failed! There are vulnerabilities to be fixed${NC}"
4851
exit 1

0 commit comments

Comments
 (0)