Skip to content

🏃 Migrate CI to self-hosted runners #3

🏃 Migrate CI to self-hosted runners

🏃 Migrate CI to self-hosted runners #3

Workflow file for this run

name: Env
on:
push:
branches: [ main ]
pull_request:
paths:
# Run only when relevant files are modified
- ".github/**.yml"
- "examples/**.py"
- "scripts/**.py"
- "tests/**.py"
- "trl/**.py"
- "setup.py"
env:
TQDM_DISABLE: 1
CI_SLACK_CHANNEL: ${{ secrets.CI_PUSH_MAIN_CHANNEL }}
jobs:
tests:
name: Env
strategy:
matrix:
python-version: ['3.9', '3.10', '3.11', '3.12']
fail-fast: false
runs-on:
group: aws-g4dn-2xlarge
container:
image: nvidia/cuda:12.8.1-cudnn-devel-ubuntu24.04
defaults:
run:
shell: bash
if: github.event.pull_request.draft == false
steps:
- name: Git checkout
uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
pip install torch
- name: Test with pytest
run: |
python -c "import torch; print(torch.cuda.get_device_name(0))"