Skip to content

Commit cf2a792

Browse files
committed
This branch adds a dockerized environment to reproduce the issues that the CI faced with Ubuntu 24.04 and secp256k1.
Usage: ```sh bash ./tests/test-ubuntu-24.04-docker.sh ``` Then use the upper arrow to run tests with `hatch`.
1 parent 24c3e31 commit cf2a792

File tree

2 files changed

+24
-0
lines changed

2 files changed

+24
-0
lines changed

tests/test-ubuntu-24.04-docker.sh

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
#!/usr/bin/env bash
2+
3+
set -euo pipefail
4+
5+
podman build -t aleph-sdk-ubuntu:24.04 -f tests/ubuntu-24.04.dockerfile .
6+
podman run -ti --rm -v $(pwd):/mnt aleph-sdk-ubuntu:24.04 bash

tests/ubuntu-24.04.dockerfile

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
FROM ubuntu:24.04
2+
3+
RUN apt-get update && apt-get install -y \
4+
python3 \
5+
python3-pip \
6+
python3-venv \
7+
libsecp256k1-dev \
8+
&& rm -rf /var/lib/apt/lists/*
9+
10+
# Create a working virtual environment \
11+
RUN python3 -m venv /opt/venv
12+
RUN /opt/venv/bin/python -m pip install --upgrade pip hatch
13+
14+
WORKDIR /mnt
15+
VOLUME /mnt
16+
17+
# Make it easy to run the tests with the upper arrow
18+
RUN echo "/opt/venv/bin/hatch run testing:test" >> /root/.bash_history

0 commit comments

Comments
 (0)