-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from uclahs-cds/maotian-create-initial-commit
Create docker image for bam-readcount 0.8.0
- Loading branch information
Showing
5 changed files
with
107 additions
and
55 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
## Description | ||
|
||
<!--Provide a brief summary of the PR here--> | ||
|
||
<!--- Please read each of the following items and confirm by replacing the [ ] with a [X] ---> | ||
## Checklist | ||
|
||
### Formatting | ||
|
||
- [ ] I have read the [code review guidelines](https://confluence.mednet.ucla.edu/display/BOUTROSLAB/Code+Review+Guidelines) and the [code review best practice on GitHub check-list](https://confluence.mednet.ucla.edu/display/BOUTROSLAB/Code+Review+Best+Practice+on+GitHub+-+Check+List). | ||
|
||
- [ ] The name of the branch is meaningful and well formatted following the [standards](https://confluence.mednet.ucla.edu/display/BOUTROSLAB/Code+Review+Best+Practice+on+GitHub+-+Check+List), using [AD_username (or 5 letters of AD if AD is too long)-[brief_description_of_branch]. | ||
|
||
- [ ] I have set up or verified the branch protection rule following the [github standards](https://confluence.mednet.ucla.edu/pages/viewpage.action?spaceKey=BOUTROSLAB&title=GitHub+Standards#GitHubStandards-Branchprotectionrule) before opening this pull request. | ||
|
||
### File Updates | ||
|
||
- [ ] I have updated the version number/dependencies and added my name to the maintainer listing in the `Dockerfile`. | ||
|
||
- [ ] I have updated the version number/feature changes in the `README.md`. | ||
|
||
<!--- This acknowledgement is optional if you do not want to be listed---> | ||
- [ ] I have updated the version number and added my name to the contributors listing in the `metadata.yaml`. | ||
|
||
- [ ] I have added the changes included in this pull request to the `CHANGELOG.md` under the next release version or unreleased, and updated the date. | ||
|
||
<!---If any previous versions have bugs, add "deprecated" in the version tag and list the bug in the corresponding release---> | ||
- [ ] I have drafted the new version release with any addidtions/changes and have linked the `CHANGELOG.md` in the release. | ||
|
||
### Docker Hub Auto Build Rules | ||
|
||
- [ ] I have created automated build rules following [this page](https://confluence.mednet.ucla.edu/display/BOUTROSLAB/How+to+set+up+automated+builds+for+Docker+Hub) and I have not manually pushed this Docker image to the `blcdsdockerregistry` on [Docker Hub](https://hub.docker.com). | ||
|
||
### Docker Image Testing | ||
|
||
- [ ] I have tested the Docker image with the `docker run` command as described below. | ||
|
||
Test the Docker image with at least one A-mini sample. Verify the new Docker image works using: | ||
|
||
```docker run -u $(id -u):$(id -g) –w <working-directory> -v <directory-you-want-to-mount>:<how-you-want-to-mount-it-within-the-docker> --rm <docker-image-name> <command-to-the-docker-with-all-parameters>``` | ||
|
||
My command: | ||
|
||
```Provide the command you ran here``` | ||
|
||
<!--- Copy and paste the results list below for more cases that were tested---> | ||
<!--- If the case addresses an issue that should be closed, begin with "Closes <Issue #>"---> | ||
## Testing Results | ||
|
||
Closes #<!--Issue #--> | ||
|
||
- Case 1 | ||
- sample: <!-- e.g. A-mini S2.T-1, A-mini S2.T-n1 --> | ||
- input files: <!--path to input file(s) (if more than one, list in indented bullet points below this line)--> | ||
- config: <!--path to config file--> | ||
- output: <!--path to output directory--> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,30 @@ | ||
FROM blcdsdockerregistry/bl-base:1.0.0 AS builder | ||
FROM ubuntu:20.04 | ||
ARG BAM_READCOUNT_VERSION=0.8.0 | ||
ARG BAM_READCOUNT_SHA512=ef2acdc9e9b581cb0e4ccea51e3cb445394733f9812f68790a171b71d5f2f089f73aa39a62a6ddf372baa174b884f7d1e52f3f2c9a2abb716599fd7832501a97 | ||
RUN apt-get update \ | ||
&& DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends\ | ||
build-essential \ | ||
git-core \ | ||
cmake \ | ||
zlib1g-dev \ | ||
libncurses-dev \ | ||
patch \ | ||
wget \ | ||
ca-certificates \ | ||
&& rm -rf /var/lib/apt/lists/* | ||
|
||
# Use conda to install tools and dependencies into /usr/local | ||
ARG TOOL_VERSION=X.X.X | ||
RUN conda create -qy -p /usr/local \ | ||
-c bioconda \ | ||
-c conda-forge \ | ||
tool_name==${TOOL_VERSION} | ||
WORKDIR / | ||
RUN wget https://github.com/genome/bam-readcount/archive/refs/tags/v${BAM_READCOUNT_VERSION}.tar.gz && \ | ||
echo "${BAM_READCOUNT_SHA512} v${BAM_READCOUNT_VERSION}.tar.gz" | sha512sum --strict -c - && \ | ||
tar xzf v${BAM_READCOUNT_VERSION}.tar.gz &&\ | ||
rm v${BAM_READCOUNT_VERSION}.tar.gz | ||
|
||
# Deploy the target tools into a base image | ||
FROM ubuntu:20.04 | ||
COPY --from=builder /usr/local /usr/local | ||
RUN mkdir bam-readcount \ | ||
&& cd bam-readcount \ | ||
&& cmake /bam-readcount-${BAM_READCOUNT_VERSION} \ | ||
&& make \ | ||
&& rm -rf /bam-readcount-v${BAM_READCOUNT_VERSION} \ | ||
&& ln -s /bam-readcount/bin/bam-readcount /usr/local/bin/bam-readcount | ||
|
||
LABEL maintainer="Your Name <[email protected]>" | ||
WORKDIR /app | ||
CMD ["bash"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
--- | ||
Category: 'docker' | ||
Description: 'Template Docker repository for tool_name' # Description of why the repository exists | ||
Maintainers: ['YourName@mednet.ucla.edu'] # email address of maintainers | ||
Contributors: ['Your Name'] # Full names of contributors | ||
Description: 'Docker repository for bam-readcount' # Description of why the repository exists | ||
Maintainers: ['[email protected]', 'maotian@mednet.ucla.edu'] # email address of maintainers | ||
Contributors: ['Caden Bugh', 'Mao Tian'] # Full names of contributors | ||
Languages: ['Dockerfile'] # programming languages used | ||
Tools: ['tool_name'] # Name of the tool(s) used in the Dockerfile | ||
Version: ['X.X.X'] # Tool version number | ||
Purpose of tool: '' # Description of what this tool does | ||
References: '' # is the tool/dependencies published, is there a confluence page | ||
Tools: ['bam-readcount'] # Name of the tool(s) used in the Dockerfile | ||
Version: ['0.8.0'] # Tool version number | ||
Purpose of tool: 'a utility that counts DNA sequence reads in BAM and CRAM files.' # Description of what this tool does | ||
References: 'Khanna, Ajay et al. “Bam-readcount -- rapid generation of basepair-resolution sequence metrics.” ArXiv arXiv:2107.12817v1. 27 Jul. 2021 Preprint.' # is the tool/dependencies published, is there a confluence page |