Skip to content

Commit

Permalink
Dockerfile: move binaries to /s3gw instead
Browse files Browse the repository at this point in the history
Instead of moving binaries and libraries to /radosgw, lets keep things
in /s3gw instead, as yet another way to abstract what we are using
below.

Signed-off-by: Joao Eduardo Luis <[email protected]>
  • Loading branch information
jecluis committed Oct 21, 2023
1 parent b214906 commit 98da49d
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,12 @@ RUN zypper -n install \
libboost_thread1_80_0 && \
zypper clean --all && \
mkdir -p \
/radosgw/bin \
/radosgw/lib \
/s3gw/bin \
/s3gw/lib \
/data

ENV PATH=/radosgw/bin:$PATH
ENV LD_LIBRARY_PATH=/radosgw/lib:$LD_LIBRARY_PATH
ENV PATH=/s3gw/bin:$PATH
ENV LD_LIBRARY_PATH=/s3gw/lib:$LD_LIBRARY_PATH

FROM s3gw-base as buildenv

Expand Down Expand Up @@ -154,17 +154,17 @@ RUN zypper -n install --no-recommends \
gmock && \
zypper clean --all

COPY --from=buildenv /srv/ceph/build/bin/unittest_rgw_* /radosgw/bin/
COPY --from=buildenv /srv/ceph/build/bin/unittest_rgw_* /s3gw/bin/
COPY --from=buildenv [ \
"/srv/ceph/build/lib/librados.so", \
"/srv/ceph/build/lib/librados.so.2", \
"/srv/ceph/build/lib/librados.so.2.0.0", \
"/srv/ceph/build/lib/libceph-common.so", \
"/srv/ceph/build/lib/libceph-common.so.2", \
"/radosgw/lib/" ]
"/s3gw/lib/" ]

ENTRYPOINT [ "bin/bash", "-x", "-c" ]
CMD [ "find /radosgw/bin -name \"unittest_rgw_*\" -print0 | xargs -0 -n1 bash -ec"]
CMD [ "find /s3gw/bin -name \"unittest_rgw_*\" -print0 | xargs -0 -n1 bash -ec"]

FROM s3gw-base as s3gw

Expand All @@ -182,16 +182,16 @@ LABEL quay.expires-after=${QUAY_EXPIRATION}

VOLUME ["/data"]

COPY --from=buildenv /srv/ceph/build/bin/radosgw /radosgw/bin
COPY --from=buildenv /srv/ceph/build/bin/radosgw /s3gw/bin
COPY --from=buildenv [ \
"/srv/ceph/build/lib/librados.so", \
"/srv/ceph/build/lib/librados.so.2", \
"/srv/ceph/build/lib/librados.so.2.0.0", \
"/srv/ceph/build/lib/libceph-common.so", \
"/srv/ceph/build/lib/libceph-common.so.2", \
"/radosgw/lib/" ]
"/s3gw/lib/" ]

COPY tools/run-s3gw.sh /radosgw/bin/
COPY tools/run-s3gw.sh /s3gw/bin/

EXPOSE 7480
EXPOSE 7481
Expand Down

0 comments on commit 98da49d

Please sign in to comment.