nextflow-io / rnaseq-nf

A proof of concept of RNAseq pipeline
Apache License 2.0
72 stars 103 forks source link

Running on M1 macs #7

Open f6v opened 3 years ago

f6v commented 3 years ago

This is a long shot, but I'll try anyway. I'm trying to run this with Docker on M1 Mac. Here's the error:

➜  nextflow nextflow run nextflow-io/rnaseq-nf -with-docker
N E X T F L O W  ~  version 21.04.1
Launching `nextflow-io/rnaseq-nf` [tender_volhard] - revision: 1f5a9060aa [master]
 R N A S E Q - N F   P I P E L I N E
 ===================================
 transcriptome: /Users/f6v/.nextflow/assets/nextflow-io/rnaseq-nf/data/ggal/ggal_1_48850000_49020000.Ggal71.500bpflank.fa
 reads        : /Users/f6v/.nextflow/assets/nextflow-io/rnaseq-nf/data/ggal/*_{1,2}.fq
 outdir       : results

executor >  local (3)
[78/8554c0] process > RNASEQ:INDEX (ggal_1_48850000_49020000) [  0%] 0 of 1
executor >  local (3)
[-        ] process > RNASEQ:INDEX (ggal_1_48850000_49020000) -
[8b/e55b25] process > RNASEQ:FASTQC (FASTQC on ggal_liver)    [100%] 1 of 1, failed: 1
[-        ] process > RNASEQ:QUANT                            -
[-        ] process > MULTIQC                                 -
Error executing process > 'RNASEQ:FASTQC (FASTQC on ggal_gut)'

Caused by:
  Process `RNASEQ:FASTQC (FASTQC on ggal_gut)` terminated with an error exit status (139)

Command executed:

  fastqc.sh "ggal_gut" "ggal_gut_1.fq ggal_gut_2.fq"

Command exit status:
  139

Command output:
  (empty)

Command error:
  WARNING: The requested image's platform (linux/amd64) does not match the detected host platform (linux/arm64/v8) and no specific platform was requested
  /home/micromamba/.bashrc: line 50: PS1: unbound variable
  qemu: uncaught target signal 11 (Segmentation fault) - core dumped
  /Users/f6v/.nextflow/assets/nextflow-io/rnaseq-nf/bin/fastqc.sh: line 6:    59 Segmentation fault      fastqc -o fastqc_${sample_id}_logs -f fastq -q ${reads}

Work dir:
  /Users/f6v/dev/nextflow/work/49/1b3cb66e3a0f16b96b37a01649e29b

Tip: you can replicate the issue by changing to the process work dir and entering the command `bash .command.run`

I'm new to Docker on ARM, but it seems like a wrong image is pulled? The base image should be available for arm64, should I force it somehow?

Thanks!

pditommaso commented 3 years ago

There's not an easy solution to this. Upstream problem is that Salmon is not available as natively compiled on ARM (via Bioconda). Therefore the container downloaded is the one for AMD/Intel arch which should run via qemu compatibility layer. Howeber the latter is failing due to a bug https://github.com/docker/for-mac/issues/5123

pditommaso commented 3 years ago

See also https://github.com/COMBINE-lab/salmon/issues/556

f6v commented 3 years ago

Thanks for getting back to me! Seems like I'm stuck with VPS instances for the time being.

jorgeaguileraseqera commented 2 years ago

it seems solved, see

https://nextflow.slack.com/archives/C02T98A23U7/p1652104483904449?thread_ts=1652102847.144039&cid=C02T98A23U7

drpatelh commented 2 years ago

I personally don't use a MAC but would this help? https://github.com/abiosoft/colima

You can set --arch options.

pditommaso commented 2 years ago

Best trick ever

export DOCKER_DEFAULT_PLATFORM=linux/amd64