From 94f7dec293a280547705cb3079c49ddb15faaf89 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rn=20Friedrich=20Dreyer?= Date: Tue, 5 Mar 2024 13:03:26 +0100 Subject: [PATCH] fix ceph build MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Jörn Friedrich Dreyer --- Dockerfile.revad | 2 +- Dockerfile.revad-ceph | 22 ++++++++++++++++------ changelog/unreleased/fix-ceph-build.md | 3 +++ 3 files changed, 20 insertions(+), 7 deletions(-) create mode 100644 changelog/unreleased/fix-ceph-build.md diff --git a/Dockerfile.revad b/Dockerfile.revad index 5bca9ef425..b83c3a135c 100644 --- a/Dockerfile.revad +++ b/Dockerfile.revad @@ -34,7 +34,7 @@ COPY . . RUN make build-revad-docker && \ cp /go/src/github/cs3org/reva/cmd/revad/revad /go/bin/revad -RUN mkdir -p /etc/revad/ && echo "" > /etc/revad/revad.toml +RUN mkdir -p /etc/revad/ && touch /etc/revad/revad.toml FROM golang:1.21-alpine3.18 diff --git a/Dockerfile.revad-ceph b/Dockerfile.revad-ceph index 9e8f8d36f6..39699332bd 100644 --- a/Dockerfile.revad-ceph +++ b/Dockerfile.revad-ceph @@ -16,9 +16,14 @@ # granted to it by virtue of its status as an Intergovernmental Organization # or submit itself to any jurisdiction. -FROM quay.io/ceph/ceph:v16 +FROM quay.io/ceph/ceph:v18 -RUN dnf update --exclude=ceph-iscsi -y && dnf install -y \ +# replace repo url with one that allows downloading the repo metadata +# if http://download.ceph.com/rpm-reef/el8/x86_64/repodata/repomd.xml works again this can be dropped +RUN sed -i 's/download.ceph.com/de.ceph.com/' /etc/yum.repos.d/ceph.repo +RUN mkdir -p /etc/selinux/config + +RUN dnf update --exclude=ceph-iscsi,chrony -y && dnf install -y \ git \ gcc \ make \ @@ -26,7 +31,7 @@ RUN dnf update --exclude=ceph-iscsi -y && dnf install -y \ librbd-devel \ librados-devel -ADD https://golang.org/dl/go1.21.5.linux-amd64.tar.gz \ +ADD https://go.dev/dl/go1.21.5.linux-amd64.tar.gz \ go1.21.5.linux-amd64.tar.gz RUN rm -rf /usr/local/go && \ @@ -38,13 +43,18 @@ ENV GOPATH /go WORKDIR /go/src/github/cs3org/reva COPY . . + +ARG GIT_COMMIT +ARG VERSION +ENV GIT_COMMIT=$GIT_COMMIT +ENV VERSION=$VERSION RUN mkdir -p /go/bin && \ - make build-revad-cephfs-docker && \ - cp /go/src/github/cs3org/reva/cmd/revad/revad /usr/bin/revad + make build-revad-cephfs-docker && \ + cp /go/src/github/cs3org/reva/cmd/revad/revad /usr/bin/revad RUN cp -r examples/ceph /etc/ -RUN mkdir -p /etc/revad/ && echo "" > /etc/revad/revad.toml +RUN mkdir -p /etc/revad/ && touch /etc/revad/revad.toml EXPOSE 9999 10000 diff --git a/changelog/unreleased/fix-ceph-build.md b/changelog/unreleased/fix-ceph-build.md new file mode 100644 index 0000000000..0e03afbef9 --- /dev/null +++ b/changelog/unreleased/fix-ceph-build.md @@ -0,0 +1,3 @@ +Bugfix: Fix ceph build + +https://github.com/cs3org/reva/pull/4557