Skip to content

Commit

Permalink
fix tests: add USE_BROTLI in relevant Dockerfiles
Browse files Browse the repository at this point in the history
search for Dockerfiles that run 'make [some_walg_build_rule]' at
docker build time, and set "ENV USE_BROTLI 1" in those Dockerfiles
  • Loading branch information
LeGEC committed Dec 5, 2022
1 parent 06a838b commit aa4a6a0
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 1 deletion.
1 change: 1 addition & 0 deletions docker/fdb_tests/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ COPY cmd/ cmd/
COPY main/ main/
COPY utility/ utility/
COPY Makefile Makefile
ENV USE_BROTLI 1

RUN sed -i 's|#cgo LDFLAGS: -lbrotli.*|&-static -lbrotlicommon-static -lm|' \
vendor/github.com/google/brotli/go/cbrotli/cgo.go && \
Expand Down
2 changes: 1 addition & 1 deletion docker/gp_tests/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ COPY cmd/ cmd/
COPY main/ main/
COPY utility/ utility/
COPY Makefile Makefile

ENV USE_BROTLI 1

RUN sed -i 's|#cgo LDFLAGS: -lbrotli.*|&-static -lbrotlicommon-static -lm|' \
vendor/github.com/google/brotli/go/cbrotli/cgo.go && \
Expand Down
2 changes: 2 additions & 0 deletions tests_func/Dockerfile.mongodb
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ ARG MONGO_VERSION=
ARG MONGO_TOOLS_VERSION=100.4.0
ENV TMP_DIR /var/tmp/wal-g
ENV WALG_CONF_DIR /etc/wal-g/
ENV USE_BROTLI 1

RUN echo "deb http://$MONGO_REPO/apt/ubuntu bionic/${MONGO_PACKAGE}/${MONGO_MAJOR} multiverse" | tee "/etc/apt/sources.list.d/mongodb_${MONGO_MAJOR}.list" && \
wget -qO - https://www.mongodb.org/static/pgp/server-${MONGO_MAJOR}.asc | apt-key add -
Expand Down Expand Up @@ -48,6 +49,7 @@ COPY staging/wal-g ${WALG_REPO}/

WORKDIR ${WALG_REPO}


RUN make link_external_deps
RUN make BUILD_ARGS=-race mongo_build && \
cp main/mongo/wal-g /usr/bin/wal-g
1 change: 1 addition & 0 deletions tests_func/Dockerfile.redis
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ ENV USER redis
ENV GROUP redis
ENV USERGROUP $USER:$GROUP
ENV HOME /home/$USER
ENV USE_BROTLI 1

# add our user and group first to make sure their IDs get assigned consistently, regardless of whatever dependencies get added
RUN groupadd -r -g 999 $USER && useradd -r -g $GROUP -u 999 $USER
Expand Down

0 comments on commit aa4a6a0

Please sign in to comment.