PharmGKB / pgkb-ngs-pipeline

PharmGKB NGS Pipeline
Mozilla Public License 2.0
17 stars 6 forks source link

building from docker "No space left on device" error #1

Open rgiannico opened 5 years ago

rgiannico commented 5 years ago

Hello, is this repo still active?

I found some problems building the docker:

Problem1 (probably solved) : Package python-software-properties not available

$ git clone https://github.com/PharmGKB/pgkb-ngs-pipeline.git
$ cd pgkb-ngs-pipeline
$ docker build -t pharmngs .
[ ... ]
Step 3 : RUN apt-get -y install zlib1g-dev vim python-software-properties apt-file software-properties-common build-essential curl git python-setuptools ruby
 ---> Running in 54e6931eb441
Reading package lists...
Building dependency tree...
Reading state information...
Package python-software-properties is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
However the following packages replace it:
  software-properties-common

E: Package 'python-software-properties' has no installation candidate
The command '/bin/sh -c apt-get -y install zlib1g-dev vim python-software-properties apt-file software-properties-common build-essential curl git python-setuptools ruby' returned a non-zero code: 100

I simply deleted this string "python-software-properties" from this line of the Dockerfile: RUN apt-get -y install zlib1g-dev vim python-software-properties apt-file software-properties-common build-essential curl git python-setuptools ruby I hope "software-properties-common" to be sufficient, but I am not sure if this fixes the docker building because of problem 2. (see below)

Problem2 (unsolved) : No space left on device

$ docker build -t pharmngs .
[ ... ]
Step 14 : RUN mkdir external_data && mkdir external_data/genome && curl -o external_data/genome/GCA_000001405.15_GRCh38_no_alt_analysis_set.fna.fai ftp://ftp.ncbi.nlm.nih.gov/genomes/all/GCA/000/001/405/GCA_000001405.15_GRCh38/seqs_for_alignment_pipelines.ucsc_ids/GCA_000001405.15_GRCh38_no_alt_analysis_set.fna.fai && curl -o external_data/genome/GCA_000001405.15_GRCh38_no_alt_analysis_set.fna.gz ftp://ftp.ncbi.nlm.nih.gov/genomes/all/GCA/000/001/405/GCA_000001405.15_GRCh38/seqs_for_alignment_pipelines.ucsc_ids/GCA_000001405.15_GRCh38_no_alt_analysis_set.fna.gz && gunzip -c external_data/genome/GCA_000001405.15_GRCh38_no_alt_analysis_set.fna.gz  > external_data/genome/GCA_000001405.15_GRCh38_no_alt_analysis_set.fna && bwa index external_data/genome/GCA_000001405.15_GRCh38_no_alt_analysis_set.fna
 ---> Running in e48c792ba2e9
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  7804  100  7804    0     0   3614      0  0:00:02  0:00:02 --:--:--  3612
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  832M  100  832M    0     0  9007k      0  0:01:34  0:01:34 --:--:-- 8237k

gzip: stdout: No space left on device
The command '/bin/sh -c mkdir external_data && mkdir external_data/genome && curl -o external_data/genome/GCA_000001405.15_GRCh38_no_alt_analysis_set.fna.fai ftp://ftp.ncbi.nlm.nih.gov/genomes/all/GCA/000/001/405/GCA_000001405.15_GRCh38/seqs_for_alignment_pipelines.ucsc_ids/GCA_000001405.15_GRCh38_no_alt_analysis_set.fna.fai && curl -o external_data/genome/GCA_000001405.15_GRCh38_no_alt_analysis_set.fna.gz ftp://ftp.ncbi.nlm.nih.gov/genomes/all/GCA/000/001/405/GCA_000001405.15_GRCh38/seqs_for_alignment_pipelines.ucsc_ids/GCA_000001405.15_GRCh38_no_alt_analysis_set.fna.gz && gunzip -c external_data/genome/GCA_000001405.15_GRCh38_no_alt_analysis_set.fna.gz  > external_data/genome/GCA_000001405.15_GRCh38_no_alt_analysis_set.fna && bwa index external_data/genome/GCA_000001405.15_GRCh38_no_alt_analysis_set.fna' returned a non-zero code: 1

I think it happens because including the genome file inside the docker produces a huge docker image, any idea how to solve this?

markwoon commented 5 years ago

We're not actively working on this repo. It is really intended as an example for others who are trying to get their data into a format usable by PharmCAT.

I've incorporated you fix for #1 so future users won't run into it again.

Regarding the "no space left on device", I found this https://bobcares.com/blog/docker-container-size/ after a quick Google search. Let me know if it helps.