Skip to content

Unable to build MMSplice Docker container on M2 Mac #2

@Kevin-G-Chen

Description

@Kevin-G-Chen

Hello,

I am encountering issues when building the MMSplice Docker container on an M2 Mac. As per the instructions in the GitHub, I have pulled MMSplice into the Introme folder, and have retained the original Dockerfile as specified here. When I attempt to build the container via docker build -t mmsplice ., I encounter the following error:

=> ERROR [ 6/18] RUN wget --quiet https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh  -O ./miniconda.sh &&     /bin/bash ./miniconda.sh -b -p /opt/conda &&     rm ./miniconda.sh       14.4s
------                                                                                                                                                                                                            
 > [ 6/18] RUN wget --quiet https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh  -O ./miniconda.sh &&     /bin/bash ./miniconda.sh -b -p /opt/conda &&     rm ./miniconda.sh:                   
13.59 PREFIX=/opt/conda                                                                                                                                                                                           
14.16 Unpacking payload ...                                                                                                                                                                                       
14.16 rosetta error: failed to open elf at /lib64/ld-linux-x86-64.so.2                                                                                                                                            
14.16  ./miniconda.sh: line 442:    43 Exit 141                extract_range $boundary1 $boundary2
14.16         44 Trace/breakpoint trap   | CONDA_QUIET="$BATCH" "$CONDA_EXEC" constructor --extract-tarball --prefix "$PREFIX"
------

 3 warnings found (use --debug to expand):
 - LegacyKeyValueFormat: "ENV key=value" should be used instead of legacy "ENV key value" format (line 5)
 - LegacyKeyValueFormat: "ENV key=value" should be used instead of legacy "ENV key value" format (line 7)
 - WorkdirRelativePath: Relative workdir "./mmsplice" can have unexpected results if the base image changes (line 31)
Dockerfile:16
--------------------
  15 |     # conda installation
  16 | >>> RUN wget --quiet https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh  -O ./miniconda.sh && \
  17 | >>>     /bin/bash ./miniconda.sh -b -p /opt/conda && \
  18 | >>>     rm ./miniconda.sh
  19 |     
--------------------
ERROR: failed to solve: process "/bin/sh -c wget --quiet https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh  -O ./miniconda.sh &&     /bin/bash ./miniconda.sh -b -p /opt/conda &&     rm ./miniconda.sh" did not complete successfully: exit code: 133

Given this may originate from me using an M2 Mac, I did also attempt to build via docker build --platform linux/amd64 -t mmsplice ., however this returned an error relating to Python installation:

 => ERROR [ 7/18] RUN conda install python=3.6                                                                                                                                                               8.3s 
------                                                                                                                                                                                                            
 > [ 7/18] RUN conda install python=3.6:                                                                                                                                                                          
1.359 Channels:                                                                                                                                                                                                   
1.359  - defaults                                                                                                                                                                                                 
1.359 Platform: linux-64                                                                                                                                                                                          
1.359 Collecting package metadata (repodata.json): ...working... done                                                                                                                                             
4.892 Solving environment: ...working... failed
8.076 
8.076 LibMambaUnsatisfiableError: Encountered problems while solving:
8.076   - package anaconda-anon-usage-0.4.0-py38hc06175d_0 requires python >=3.8,<3.9.0a0, but none of the providers can be installed
8.076 
8.076 Could not solve for environment specs
8.076 The following packages are incompatible
8.076 ├─ anaconda-anon-usage is installable with the potential options
8.076 │  ├─ anaconda-anon-usage [0.2.0|0.3.0|...|0.4.4] would require
8.076 │  │  └─ python >=3.8,<3.9.0a0 , which can be installed;
8.076 │  ├─ anaconda-anon-usage [0.4.3|0.4.4] would require
8.076 │  │  └─ python >=3.12,<3.13.0a0 , which can be installed;
8.076 │  ├─ anaconda-anon-usage [0.2.0|0.3.0|...|0.4.4] would require
8.076 │  │  └─ python >=3.10,<3.11.0a0 , which can be installed;
8.076 │  ├─ anaconda-anon-usage [0.2.0|0.3.0|...|0.4.4] would require
8.076 │  │  └─ python >=3.11,<3.12.0a0 , which can be installed;
8.076 │  └─ anaconda-anon-usage [0.2.0|0.3.0|...|0.4.4] would require
8.076 │     └─ python >=3.9,<3.10.0a0 , which can be installed;
8.076 └─ python 3.6**  is not installable because it conflicts with any installable versions previously reported.
8.076 
------

 3 warnings found (use --debug to expand):
 - LegacyKeyValueFormat: "ENV key=value" should be used instead of legacy "ENV key value" format (line 5)
 - LegacyKeyValueFormat: "ENV key=value" should be used instead of legacy "ENV key value" format (line 7)
 - WorkdirRelativePath: Relative workdir "./mmsplice" can have unexpected results if the base image changes (line 31)
Dockerfile:21
--------------------
  19 |     
  20 |     # python pip updates
  21 | >>> RUN conda install python=3.6
  22 |     RUN conda config --add channels bioconda
  23 |     RUN conda install cyvcf2 -y
--------------------
ERROR: failed to solve: process "/bin/sh -c conda install python=3.6" did not complete successfully: exit code: 1

It would seem there are issues with Conda and Python installation in the Dockerfile - however I am unsure what specific versions should be installed, or if I am approaching this the wrong way. Could you advise on how I should proceed with the installation?

Thanks,
Kevin

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions