Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Dockerfile.revad-eos #3706

Merged
merged 1 commit into from
Mar 7, 2023
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
3 changes: 3 additions & 0 deletions changelog/unreleased/fix-docker-eos.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
Bugfix: Fix revad-eos docker image which was failing to build

https://github.com/cs3org/reva/pull/3706
32 changes: 12 additions & 20 deletions docker/Dockerfile.revad-eos
Original file line number Diff line number Diff line change
Expand Up @@ -16,35 +16,27 @@
# granted to it by virtue of its status as an Intergovernmental Organization
# or submit itself to any jurisdiction.

FROM gitlab-registry.cern.ch/dss/eos/eos-fusex:4.8.91 as builder
FROM golang:alpine3.16 as builder

RUN yum -y install \
gcc \
git \
golang \
make && \
yum clean all && \
rm -rf /var/cache/yum

ADD https://golang.org/dl/go1.19.linux-amd64.tar.gz \
go1.19.linux-amd64.tar.gz

RUN rm -rf /usr/local/go && \
tar -C /usr/local -xzf go1.19.linux-amd64.tar.gz && \
rm go1.19.linux-amd64.tar.gz
RUN apk --no-cache add \
ca-certificates \
make

ENV PATH /go/bin:/usr/local/go/bin:$PATH
ENV GOPATH /go

WORKDIR /go/src/github/cs3org/reva
COPY . .
RUN make revad
RUN make revad && \
cp /go/src/github/cs3org/reva/cmd/revad/revad /go/bin/revad

RUN mkdir -p /etc/revad/ && touch /etc/revad/revad.toml

FROM gitlab-registry.cern.ch/dss/eos/eos-all:4.8.91
COPY --from=builder /go/src/github/cs3org/reva/cmd/revad/revad /usr/bin/revad
RUN chmod +x /usr/bin/revad
RUN mkdir -p /etc/revad/ && \
touch /etc/revad/revad.toml

COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/
COPY --from=builder /go/bin/revad /usr/bin/revad
COPY --from=builder /etc/revad /etc/revad

ENTRYPOINT [ "/usr/bin/revad" ]
CMD [ "-c", "/etc/revad/revad.toml", "-p", "/var/run/revad.pid" ]