From 40dba12da1d5adc447bb570b94dab81e73794e1f Mon Sep 17 00:00:00 2001 From: ad-daniel Date: Wed, 27 Apr 2022 12:07:53 +0200 Subject: [PATCH] Temporary test --- .github/workflows/tests_suite.yml | 5 ++++- Dockerfile | 4 +++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.github/workflows/tests_suite.yml b/.github/workflows/tests_suite.yml index 7eca92edf8..f084aac5a2 100644 --- a/.github/workflows/tests_suite.yml +++ b/.github/workflows/tests_suite.yml @@ -146,9 +146,12 @@ jobs: - uses: actions/checkout@v2 with: submodules: true + - name: Get branch name + id: branch-name + uses: tj-actions/branch-names@v5.1 - name: Build image run: | - docker build --tag opendr/opendr-toolkit:cpu_test --file Dockerfile . + docker build --tag opendr/opendr-toolkit:cpu_test --build-arg branch=${{ steps.branch-name.outputs.current_branch }} --file Dockerfile . docker save opendr/opendr-toolkit:cpu_test > cpu_test.zip - name: Upload image artifact uses: actions/upload-artifact@v2 diff --git a/Dockerfile b/Dockerfile index 8ee99caa7b..82c44286f4 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,5 +1,7 @@ FROM ubuntu:20.04 +ARG branch + # Install dependencies RUN apt-get update && \ apt-get --yes install git sudo @@ -12,7 +14,7 @@ RUN chmod +x /tini ENTRYPOINT ["/tini", "--"] # Clone the repo and install the toolkit -RUN git clone --depth 1 --recurse-submodules -j8 https://github.com/opendr-eu/opendr +RUN git clone --depth 1 --recurse-submodules -j8 https://github.com/opendr-eu/opendr -b $branch WORKDIR "/opendr" RUN ./bin/install.sh