Skip to content

Commit

Permalink
Basically revert changes to test framework build script + Dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
MarkusPettersson98 committed Dec 12, 2023
1 parent d10527e commit a89be35
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
8 changes: 6 additions & 2 deletions test/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,2 +1,6 @@
ARG IMAGE=ghcr.io/mullvad/mullvadvpn-app-build:latest
FROM $IMAGE
FROM ghcr.io/mullvad/mullvadvpn-app-build:latest

RUN apt-get update && apt-get install -y \
gcc curl libdbus-1-dev protobuf-compiler
RUN curl https://sh.rustup.rs -sSf | sh -s -- -y
ENV PATH="/root/.cargo/bin:${PATH}"
6 changes: 2 additions & 4 deletions test/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,15 @@
set -eu

SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
APP_DIR="$SCRIPT_DIR/.."
cd "$SCRIPT_DIR"

if [[ $TARGET == x86_64-unknown-linux-gnu ]]; then
mkdir -p .container/cargo-registry
container_image=$(cat "$APP_DIR/building/linux-container-image.txt")
podman build -t mullvadvpn-app-tests --build-arg IMAGE="${container_image}" .
podman build -t mullvadvpn-app-tests .

podman run --rm -it \
-v "${SCRIPT_DIR}/.container/cargo-registry":/root/.cargo/registry \
-v "${APP_DIR}":/src:Z \
-v "${SCRIPT_DIR}/..":/src:Z \
-e CARGO_HOME=/root/.cargo/registry \
mullvadvpn-app-tests \
/bin/bash -c "cd /src/test/; cargo build --bin test-runner --release --target ${TARGET}"
Expand Down

0 comments on commit a89be35

Please sign in to comment.