name: Integration (GooseFS Docker)
on:
push:
branches: [main, master]
paths-ignore:
- "website/**"
- ".github/workflows/docs.yml"
pull_request:
paths-ignore:
- "website/**"
- ".github/workflows/docs.yml"
workflow_dispatch:
inputs:
run_macos_docker:
description: >-
Also run Docker IT on a macOS runner that already has Docker
(self-hosted M4 / Mac with Docker Desktop). GitHub-hosted
macos-14 ARM cannot nest VMs.
type: boolean
default: false
macos_runner:
description: Runner label for macOS Docker IT (e.g. macos-14 or self-hosted label)
type: string
default: macos-14
concurrency:
group: integration-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
env:
CARGO_TERM_COLOR: always
GOOSEFS_MASTER_ADDR: 127.0.0.1:9200
GOOSEFS_AUTH_TYPE: simple
GFS_ADDR: 127.0.0.1:9200
jobs:
goosefs-integration:
name: ${{ matrix.kind }}-it (${{ matrix.os }})
runs-on: ${{ matrix.os }}
timeout-minutes: 90
strategy:
fail-fast: false
max-parallel: 2
matrix:
include:
- os: ubuntu-latest
kind: rust
- os: ubuntu-latest
kind: python
python-version: "3.11"
steps:
- uses: actions/checkout@v7
- name: Setup Rust
uses: ./.github/actions/setup
- name: Install uv
if: matrix.kind == 'python'
uses: astral-sh/setup-uv@v7
with:
enable-cache: true
- name: Setup Python
if: matrix.kind == 'python'
uses: actions/setup-python@v7
with:
python-version: ${{ matrix.python-version }}
- name: Sync + build binding
if: matrix.kind == 'python'
working-directory: bindings/python
run: |
uv sync --all-extras --group dev --group test
uv run maturin develop --uv --release
- name: Setup GooseFS
uses: ./.github/actions/setup-goosefs
- name: Start Pushgateway (for metrics_pushgateway example)
if: matrix.kind == 'rust'
run: |
docker run -d --name goosefs-sdk-pushgateway -p 127.0.0.1:9091:9091 prom/pushgateway:v1.9.0
python3 - <<'PY'
import socket, time, sys
for _ in range(30):
try:
socket.create_connection(("127.0.0.1", 9091), 1).close()
print("pushgateway ready")
sys.exit(0)
except OSError:
time.sleep(1)
sys.exit("pushgateway did not become ready")
PY
- name: Rust ignored integration tests
if: matrix.kind == 'rust'
run: bash scripts/ci/run_rust_integration.sh
- name: Rust examples
if: matrix.kind == 'rust'
run: bash scripts/ci/run_rust_examples.sh
- name: Rust cluster benchmarks
if: matrix.kind == 'rust'
run: bash scripts/ci/run_rust_benchmarks.sh cluster
- name: Pytest (full, with cluster)
if: matrix.kind == 'python'
working-directory: bindings/python
run: uv run --group test pytest -v --tb=short
- name: Python examples
if: matrix.kind == 'python'
run: bash scripts/ci/run_python_examples.sh
- name: Python benchmarks
if: matrix.kind == 'python'
run: bash scripts/ci/run_python_benchmarks.sh
- name: Tear down GooseFS
if: always()
working-directory: fixtures/goosefs
run: |
docker compose -f docker-compose-goosefs.yml down -v || true
docker rm -f goosefs-sdk-pushgateway || true
macos-docker-integration:
name: macos-docker-it (${{ inputs.macos_runner }})
if: github.event_name == 'workflow_dispatch' && inputs.run_macos_docker
runs-on: ${{ inputs.macos_runner }}
timeout-minutes: 120
steps:
- uses: actions/checkout@v7
- name: Verify Docker
run: |
docker info
docker compose version
- name: Setup Rust
uses: ./.github/actions/setup
- name: Install uv
uses: astral-sh/setup-uv@v7
with:
enable-cache: true
- name: Setup Python
uses: actions/setup-python@v7
with:
python-version: "3.11"
- name: Sync + build binding
working-directory: bindings/python
run: |
uv sync --all-extras --group dev --group test
uv run maturin develop --uv --release
- name: Setup GooseFS
uses: ./.github/actions/setup-goosefs
- name: Rust ignored integration tests
run: bash scripts/ci/run_rust_integration.sh
- name: Rust examples
run: bash scripts/ci/run_rust_examples.sh
- name: Rust cluster benchmarks
run: bash scripts/ci/run_rust_benchmarks.sh cluster
- name: Pytest (full, with cluster)
working-directory: bindings/python
run: uv run --group test pytest -v --tb=short
- name: Python examples
run: bash scripts/ci/run_python_examples.sh
- name: Python benchmarks
run: bash scripts/ci/run_python_benchmarks.sh
- name: Tear down GooseFS
if: always()
working-directory: fixtures/goosefs
run: docker compose -f docker-compose-goosefs.yml down -v || true