From fb50fac643d3165fb97b6ef944a9808cd636460e Mon Sep 17 00:00:00 2001 From: Victoria Martinez de la Cruz Date: Mon, 5 Aug 2024 13:21:44 +0200 Subject: [PATCH] Use golang 1.21.0 and OpenStack RDO repos Use golang 1.21.0 instead of golang 1.21. Since 1.21 golang added the .z version, so it is now required to point to a z version Use OpenStack RDO Caracal repos to fetch dependencies --- build/Dockerfile | 12 ++++++------ build/repos/opstools.repo | 27 +++++++++++++-------------- 2 files changed, 19 insertions(+), 20 deletions(-) diff --git a/build/Dockerfile b/build/Dockerfile index ae4354b1..b776e9c5 100644 --- a/build/Dockerfile +++ b/build/Dockerfile @@ -1,19 +1,19 @@ # --- build smart gateway --- -FROM registry.access.redhat.com/ubi8:latest AS builder +FROM registry.access.redhat.com/ubi9:latest AS builder ENV GOPATH=/go -ENV D=/go/src/github.com/infrawatch/sg-core +ENV SGCORE_DIR=/go/src/github.com/infrawatch/sg-core -WORKDIR $D -COPY . $D/ +WORKDIR $SGCORE_DIR +COPY . $SGCORE_DIR/ # dependencies for qpid-proton-c COPY build/repos/opstools.repo /etc/yum.repos.d/opstools.repo RUN dnf install golang git qpid-proton-c-devel -y --setopt=tsflags=nodocs -RUN go install golang.org/dl/go1.21@latest && /go/bin/go1.21 download && PRODUCTION_BUILD=false CONTAINER_BUILD=true GOCMD=/go/bin/go1.21 ./build.sh +RUN go install golang.org/dl/go1.21.0@latest && /go/bin/go1.21.0 download && PRODUCTION_BUILD=false CONTAINER_BUILD=true GOCMD=/go/bin/go1.21.0 ./build.sh # --- end build, create smart gateway layer --- -FROM registry.access.redhat.com/ubi8-minimal:latest +FROM registry.access.redhat.com/ubi9-minimal:latest LABEL io.k8s.display-name="Smart Gateway" \ io.k8s.description="A component of the Service Telemetry Framework on the server side that ingests data from AMQP 1.x and provides a metrics scrape endpoint for Prometheus, and forwards events to ElasticSearch" \ diff --git a/build/repos/opstools.repo b/build/repos/opstools.repo index 2d95a92d..f00fa338 100644 --- a/build/repos/opstools.repo +++ b/build/repos/opstools.repo @@ -1,19 +1,18 @@ -# CentOS-OpsTools.repo +# CentOS 9 OpenStack repos # -# Please see http://wiki.centos.org/SpecialInterestGroup/OpsTools for more -# information +# Please see https://trunk.rdoproject.org/ and +# https://trunk.rdoproject.org/centos9-caracal/report.html for more information -[centos-opstools-testing] -name=CentOS-OpsTools - testing repo -baseurl=https://buildlogs.centos.org/centos/$releasever-stream/opstools/$basearch/collectd-5/ +[delorean-caracal-testing] +name=dlrn-caracal-testing +baseurl=https://trunk.rdoproject.org/centos9-caracal/deps/latest/ +enabled=1 gpgcheck=0 -enabled=0 +module_hotfixes=1 -[centos-opstools] -name=CentOS-OpsTools - collectd -#mirrorlist=http://mirrorlist.centos.org/?arch=$basearch&release=$releasever-stream&repo=opstools-collectd-5 -baseurl=http://vault.centos.org/$releasever-stream/opstools/$basearch/collectd-5/ -gpgcheck=0 +[centos9-opstools] +name=centos9-opstools +baseurl=http://mirror.stream.centos.org/SIGs/9-stream/opstools/$basearch/collectd-5/ enabled=1 -skip_if_unavailable=1 -gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-OpsTools +gpgcheck=0 +module_hotfixes=1