Skip to content

Commit

Permalink
test: Minor fixes to expose the certs in a subdirectory too
Browse files Browse the repository at this point in the history
We were mapping the ports and the source into the docker image, but we
were not mapping the certs out into the host. Without this the host
could not connect as it had no valid certificates to check against.
  • Loading branch information
cdecker committed Dec 18, 2024
1 parent 5cc52bb commit 0341cf9
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 9 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ gltestserver-image: docker/gl-testserver/Dockerfile
--build-arg DOCKER_USER=$(shell whoami) \
--build-arg UID=$(shell id -u) \
--build-arg GID=$(shell id -g) \
--build-arg REPO_PATH=$(shell git rev-parse --show-superproject-working-tree) \
--build-arg REPO_PATH=$(shell git rev-parse --show-toplevel) \
-t gltestserver \
-f docker/gl-testserver/Dockerfile \
.
Expand Down
19 changes: 11 additions & 8 deletions docker/gl-testserver/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,20 +1,22 @@
FROM ubuntu:22.04 AS python-builder

ENV RUST_VERSION=1.74
ENV PATH=$CARGO_HOME/bin:$PATH
ENV PROTOC_VERSION=3.19.3
ENV CFSSL_VERSION=1.6.5
ENV GL_TESTING_IGNORE_HASH=true
ARG BITCOIN_VERSION=24.0
ARG GID=0
ARG UID=0
ARG DOCKER_USER=dev
ARG REPO_PATH=/repo

ENV RUST_VERSION=1.74
ENV PATH=$CARGO_HOME/bin:$PATH
ENV PROTOC_VERSION=3.19.3
ENV CFSSL_VERSION=1.6.5
ENV GL_TESTING_IGNORE_HASH=true
ENV PATH=$PATH:/home/$DOCKER_USER/.local/bin/:/opt/bitcoin/bin:/home/$DOCKER_USER/.cargo/bin
#ENV VIRTUAL_ENV=/tmp/venv
ENV CARGO_TARGET_DIR=/tmp/cargo
ENV REPO=$REPO_PATH

# Force this target dir, so the scripts can find all the binaries.
ENV CARGO_TARGET_DIR=$REPO/target

RUN apt update && apt install -qqy \
curl \
python3 \
Expand Down Expand Up @@ -57,6 +59,7 @@ RUN mkdir -p ${REPO_PATH} && \

ADD ../../ ${REPO_PATH}/
RUN chown $DOCKER_USER:users -R ${REPO_PATH}
RUN chown $DOCKER_USER:users -R /home/$DOCKER_USER
USER $DOCKER_USER

RUN curl \
Expand All @@ -72,4 +75,4 @@ WORKDIR ${REPO_PATH}/libs/gl-testserver/

RUN uv sync --locked -v
RUN uv run clnvm get-all
CMD uv run gltestserver run --metadata ${REPO}/
CMD uv run gltestserver run --metadata ${REPO}/ --directory ${REPO}/.gltestserver

0 comments on commit 0341cf9

Please sign in to comment.