Skip to content

Workflow file for this run

name: Test Flux Executor
# TODO temporarily disable flux executor tests as the test container is based on Python 3.8 but Snakemake now requires Python 3.9
# on:
# pull_request: []
jobs:
build:
runs-on: ubuntu-latest
permissions:
packages: read
strategy:
fail-fast: false
matrix:
container: ["fluxrm/flux-sched:focal"]
container:
image: ${{ matrix.container }}
options: "--platform=linux/amd64 --user root -it"
name: ${{ matrix.container }}
steps:
- name: Make Space
run: |
rm -rf /usr/share/dotnet
rm -rf /opt/ghc
- name: Checkout
uses: actions/checkout@v3
- name: Setup miniconda
uses: conda-incubator/setup-miniconda@v2
with:
activate-environment: snakemake
channels: "conda-forge, bioconda"
miniforge-variant: Mambaforge
miniforge-version: latest
- name: Install Snakemake
shell: bash -el {0}
run: |
conda config --set channel_priority strict
mamba install python>=3.9 pip
# TODO remove and add as regular dependency once released
pip install git+https://github.com/snakemake/snakemake-interface-executor-plugins.git
pip install .
- name: Start Flux and Test Workflow
shell: bash -el {0}
run: |
# We must have python3->python accessible for this to work
ln -s /bin/python3 /usr/local/bin/python
su fluxuser
cd examples/flux
# This run does not use conda
which snakemake
flux start snakemake --show-failed-logs --verbose --flux --jobs=1 --no-shared-fs
- name: Test Flux with Conda
shell: bash -el {0}
run: |
which python
which conda
cp -R ./tests/test_conda /tmp/test_conda
cd /tmp/test_conda
flux start snakemake --show-failed-logs --verbose --flux --jobs=1 --use-conda --conda-frontend=conda