Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: upgrade build_rnaseq docker for newer Python version #41

Merged
merged 2 commits into from
Dec 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
54 changes: 0 additions & 54 deletions rnaseq/ccbr_build_rnaseq/Dockerfile

This file was deleted.

1 change: 1 addition & 0 deletions rnaseq/ccbr_build_rnaseq/Dockerfile
54 changes: 54 additions & 0 deletions rnaseq/ccbr_build_rnaseq/Dockerfile.v1
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
# ccbr_build_rnaseq Dockerfile (v0.0.1)
FROM ubuntu:18.04

MAINTAINER <[email protected]>, <[email protected]>

RUN mkdir -p /data2
RUN mkdir -p /opt2/ucsc/

# Update apt-get before downloading packages
RUN apt-get update && \
apt-get upgrade -y

# Install dependencies: python (2.7), python (3.6) and pip3, wget to download UCSC binaries
# samtools to install libkrb5.so.3: open shared object file (needed bby UCSC tools)
RUN DEBIAN_FRONTEND=noninteractive apt-get install --yes \
wget \
python \
bedtools \
samtools \
python3 \
python3-pip \
locales && \
apt-get clean && \
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*

WORKDIR /opt2/ucsc

# Get a controlled release of UCSC tool from my mirror: https://github.com/skchronicles/ucsc_mirror/
RUN wget https://github.com/skchronicles/ucsc_mirror/raw/main/bedSort && \
wget https://github.com/skchronicles/ucsc_mirror/raw/main/genePredToBed && \
wget https://github.com/skchronicles/ucsc_mirror/raw/main/gtfToGenePred && \
chmod a+rx /opt2/ucsc/*

# Pip install required Python dependencies
## argparse
## Bio
## HTSeq
## numpy
## scipy
## pysam
RUN pip3 install --upgrade pip
RUN pip3 install bio==0.4.1 biopython==1.78 certifi==2020.12.5 chardet==4.0.0 HTSeq==0.13.5 idna==2.10 numpy==1.19.5 pysam==0.16.0.1 requests==2.25.1 scipy==1.5.4 urllib3==1.26.4

# Set environment variable(s)
# Configure "locale", see https://github.com/rocker-org/rocker/issues/19
RUN echo "en_US.UTF-8 UTF-8" >> /etc/locale.gen \
&& locale-gen en_US.utf8 \
&& /usr/sbin/update-locale LANG=en_US.UTF-8

# Add UCSC tools to PATH
ENV PATH="/opt2/ucsc":$PATH

COPY Dockerfile /opt2/
WORKDIR /data2
38 changes: 38 additions & 0 deletions rnaseq/ccbr_build_rnaseq/Dockerfile.v2
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
# ccbr_build_rnaseq Dockerfile (v2)
FROM nciccbr/ccbr_ubuntu_22.04:v4

# build time variables
ARG BUILD_DATE="000000"
ENV BUILD_DATE=${BUILD_DATE}
ARG BUILD_TAG="000000"
ENV BUILD_TAG=${BUILD_TAG}
ARG REPONAME="000000"
ENV REPONAME=${REPONAME}

# Install conda and give write permissions to conda folder
RUN echo 'export PATH=/opt2/conda/bin:$PATH' > /etc/profile.d/conda.sh && \
wget --quiet "https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-$(uname)-$(uname -m).sh" -O ~/miniforge3.sh && \
/bin/bash ~/miniforge3.sh -b -p /opt2/conda && \
rm ~/miniforge3.sh && chmod 777 -R /opt2/conda/
ENV PATH="/opt2/conda/bin:$PATH"
RUN conda config --add channels bioconda
RUN conda config --add channels conda-forge
RUN conda config --add channels r
RUN conda upgrade conda

RUN mamba install -c bioconda \
ucsc-bedsort \
'bio>=0.4.1' \
'biopython>=1.78' \
'certifi>=2020.12.5' \
'chardet>=4.0.0' \
'HTSeq>=0.13.5' \
'idna>=2.10' \
'numpy>=1.19.5' \
'pysam>=0.16.0.1' \
'requests>=2.25.1' \
'scipy>=1.5.4' \
'urllib3==1.26.4'

COPY Dockerfile /opt2/
WORKDIR /data2
4 changes: 4 additions & 0 deletions rnaseq/ccbr_build_rnaseq/meta.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
dockerhub_namespace: nciccbr
image_name: ccbr_build_rnaseq
version: v2
container: "$(dockerhub_namespace)/$(image_name):$(version)"
Loading