Skip to content

Commit 1a94d97

Browse files
authored
Merge pull request libgit2#6343 from libgit2/ethomson/ci
ci: update dockerfiles for mbedTLS new url
2 parents a2d2769 + 5afc146 commit 1a94d97

4 files changed

Lines changed: 16 additions & 12 deletions

File tree

.github/workflows/main.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,11 @@ jobs:
241241
working-directory: ${{ env.docker-config-path }}
242242
if: matrix.platform.container.name != ''
243243
- name: Create container
244-
run: docker build -t ${{ env.docker-registry-container-sha }} -f ${{ env.dockerfile }} .
244+
run: |
245+
if [ "${{ matrix.container.base }}" != "" ]; then
246+
BASE_ARG="--build-arg BASE=${{ matrix.container.base }}"
247+
fi
248+
docker build -t ${{ env.docker-registry-container-sha }} --build-arg UID=$(id -u) --build-arg GID=$(id -g) ${BASE_ARG} -f ${{ env.dockerfile }} .
245249
working-directory: ${{ env.docker-config-path }}
246250
if: matrix.platform.container.name != '' && env.docker-container-exists != 'true'
247251
- name: Build and test

ci/docker/bionic

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,14 +28,14 @@ RUN apt-get update && \
2828

2929
FROM apt AS mbedtls
3030
RUN cd /tmp && \
31-
curl --location --silent --show-error https://tls.mbed.org/download/mbedtls-2.16.2-apache.tgz | \
32-
tar -xz && \
33-
cd mbedtls-2.16.2 && \
31+
curl --location --silent --show-error https://github.com/Mbed-TLS/mbedtls/archive/refs/tags/mbedtls-2.16.2.tar.gz | \
32+
tar -xz && \
33+
cd mbedtls-mbedtls-2.16.2 && \
3434
scripts/config.pl set MBEDTLS_MD4_C 1 && \
3535
CFLAGS=-fPIC cmake -G Ninja -DENABLE_PROGRAMS=OFF -DENABLE_TESTING=OFF -DUSE_SHARED_MBEDTLS_LIBRARY=OFF -DUSE_STATIC_MBEDTLS_LIBRARY=ON . && \
3636
ninja install && \
3737
cd .. && \
38-
rm -rf mbedtls-2.16.2
38+
rm -rf mbedtls-mbedtls-2.16.2
3939

4040
FROM mbedtls AS adduser
4141
ARG UID=""

ci/docker/focal

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,9 @@ RUN apt-get update && \
3232

3333
FROM apt AS mbedtls
3434
RUN cd /tmp && \
35-
curl --location --silent --show-error https://tls.mbed.org/download/mbedtls-2.16.2-apache.tgz | \
35+
curl --location --silent --show-error https://github.com/Mbed-TLS/mbedtls/archive/refs/tags/mbedtls-2.16.2.tar.gz | \
3636
tar -xz && \
37-
cd mbedtls-2.16.2 && \
37+
cd mbedtls-mbedtls-2.16.2 && \
3838
scripts/config.pl unset MBEDTLS_AESNI_C && \
3939
scripts/config.pl set MBEDTLS_MD4_C 1 && \
4040
mkdir build build-msan && \
@@ -45,7 +45,7 @@ RUN cd /tmp && \
4545
CC=clang-10 CFLAGS="-fPIC" cmake -G Ninja -DENABLE_PROGRAMS=OFF -DENABLE_TESTING=OFF -DUSE_SHARED_MBEDTLS_LIBRARY=ON -DUSE_STATIC_MBEDTLS_LIBRARY=OFF -DCMAKE_BUILD_TYPE=MemSanDbg -DCMAKE_INSTALL_PREFIX=/usr/local/msan .. && \
4646
ninja install && \
4747
cd .. && \
48-
rm -rf mbedtls-2.16.2
48+
rm -rf mbedtls-mbedtls-2.16.2
4949

5050
FROM mbedtls AS libssh2
5151
RUN cd /tmp && \

ci/docker/xenial

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,14 +30,14 @@ RUN apt-get update && \
3030

3131
FROM apt AS mbedtls
3232
RUN cd /tmp && \
33-
curl --location --silent --show-error https://tls.mbed.org/download/mbedtls-2.16.2-apache.tgz | \
34-
tar -xz && \
35-
cd mbedtls-2.16.2 && \
33+
curl --location --silent --show-error https://github.com/Mbed-TLS/mbedtls/archive/refs/tags/mbedtls-2.16.2.tar.gz | \
34+
tar -xz && \
35+
cd mbedtls-mbedtls-2.16.2 && \
3636
scripts/config.pl set MBEDTLS_MD4_C 1 && \
3737
CFLAGS=-fPIC cmake -G Ninja -DENABLE_PROGRAMS=OFF -DENABLE_TESTING=OFF -DUSE_SHARED_MBEDTLS_LIBRARY=OFF -DUSE_STATIC_MBEDTLS_LIBRARY=ON . && \
3838
ninja install && \
3939
cd .. && \
40-
rm -rf mbedtls-2.16.2
40+
rm -rf mbedtls-mbedtls-2.16.2
4141

4242
FROM mbedtls AS libssh2
4343
RUN cd /tmp && \

0 commit comments

Comments
 (0)