Update Dockerfiles to current conventions #166
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: "Unit tests" | |
on: [push, pull_request] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
continue-on-error: ${{ matrix.experimental }} # Experimental builds may fail | |
strategy: | |
matrix: | |
include: | |
# iRODS 4.2.7 clients on Ubuntu 16.04 | |
- irods: "4.2.7" | |
build_image: "ghcr.io/wtsi-npg/ub-16.04-irods-clients-dev-4.2.7:latest" | |
server_image: "ghcr.io/wtsi-npg/ub-16.04-irods-4.2.7:latest" | |
experimental: false | |
# iRODS 4.2.11 clients on Ubuntu 18.04 | |
- irods: "4.2.11" | |
build_image: "ghcr.io/wtsi-npg/ub-18.04-irods-clients-dev-4.2.11:latest" | |
server_image: "ghcr.io/wtsi-npg/ub-18.04-irods-4.2.11:latest" | |
experimental: false | |
# iRODS 4.2.12 clients on Ubuntu 18.04 | |
- irods: "4.2.12" | |
build_image: "ghcr.io/wtsi-npg/ub-18.04-irods-clients-dev-4.2.12:latest" | |
server_image: "ghcr.io/wtsi-npg/ub-18.04-irods-4.2.12:latest" | |
experimental: false | |
# iRODS 4.3.1 clients on Ubuntu 22.04 | |
- irods: "4.3.1" | |
build_image: "ghcr.io/wtsi-npg/ub-22.04-irods-clients-dev-4.3.1:latest" | |
server_image: "ghcr.io/wtsi-npg/ub-22.04-irods-4.3.1:latest" | |
experimental: false | |
# iRODS 4.3.2 clients on Ubuntu 22.04 | |
- irods: "4.3.2" | |
build_image: "ghcr.io/wtsi-npg/ub-22.04-irods-clients-dev-4.3.2:latest" | |
server_image: "ghcr.io/wtsi-npg/ub-22.04-irods-4.3.2:latest" | |
experimental: true | |
container: | |
image: ${{ matrix.build_image }} | |
services: | |
irods-server: | |
image: ${{ matrix.server_image }} | |
ports: | |
- "1247:1247" | |
- "20000-20199:20000-20199" | |
volumes: | |
- /dev/shm:/dev/shm | |
options: >- | |
--health-cmd "nc -z -v localhost 1247" | |
--health-start-period 60s | |
--health-interval 10s | |
--health-timeout 20s | |
--health-retries 6 | |
steps: | |
- name: "Checkout" | |
uses: actions/checkout@v3 | |
- name: "Configure iRODS clients" | |
run: | | |
mkdir -p "$HOME/.irods" | |
cat <<'EOF' > "$HOME/.irods/irods_environment.json" | |
{ | |
"irods_host": "irods-server", | |
"irods_port": 1247, | |
"irods_user_name": "irods", | |
"irods_zone_name": "testZone", | |
"irods_home": "/testZone/home/irods", | |
"irods_default_resource": "replResc" | |
} | |
EOF | |
# Without this, Actions refuses the connection between the containers: | |
nc -z -v irods-server 1247 | |
echo "irods" | script -q -c "iinit" /dev/null | |
ienv | |
ils | |
ilsresc | |
- name: "Build and test baton" | |
env: | |
CK_DEFAULT_TIMEOUT: 60 | |
ASAN_OPTIONS: "detect_leaks=0" | |
LDFLAGS: ${{ matrix.irods == '4.3.0' && '-Wl,-z,muldefs' || '' }} | |
run: | | |
# Avoid git exiting when Actions runs | |
git config --global --add safe.directory "$PWD" | |
autoreconf -fi | |
./configure --enable-address-sanitizer | |
make distcheck DISTCHECK_CONFIGURE_FLAGS="--enable-address-sanitizer LDFLAGS=\"$LDFLAGS\"" | |
- name: "Show test log" | |
if: ${{ failure() }} | |
run: | | |
find "$GITHUB_WORKSPACE" -name \*.log -exec cat {} \; |