Skip to content
Snippets Groups Projects
Commit 7cb1abb6 authored by Alex Kanitz's avatar Alex Kanitz
Browse files

test

parent 45e84a2d
No related branches found
No related tags found
1 merge request!5ci: add GitLab CI config
Pipeline #14457 failed
...@@ -3,7 +3,24 @@ default: ...@@ -3,7 +3,24 @@ default:
- shell - shell
test: test:
rules:
- if: $CI_COMMIT_BRANCH != $CI_DEFAULT_BRANCH
script: script:
- /bin/false - docker build -t testimage:latest .
- docker build -t imagetest:latest . - docker run --rm -it testimage:latest tests/test.sh
- docker run --rm -it imagetest:latest tests/test.sh
publish:
rules:
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
script:
- export VERSION=$(grep 'version <-' ascii_alignment_pileup.R | cut -f2 -d'"')
- export IMAGE="${DOCKER_ORG}/${DOCKER_REPO}:${VERSION}"
- |
docker build \
-t $IMAGE \
--build-arg version=$VERSION \
.
- docker run --rm -it $IMAGE tests/test.sh
- echo "${DOCKER_TOKEN}" | docker login -u "${DOCKER_USER}" --password-stdin
- docker push $IMAGE
##### BASE ##### ##### BASE #####
FROM rocker/r-ver:4.2.1 FROM rocker/r-ver:4.2.1
##### BUILD ARGUMENTS #####
ARG version=unknown
##### METADATA ##### ##### METADATA #####
MAINTAINER zavolab-biozentrum@unibas.ch MAINTAINER zavolab-biozentrum@unibas.ch
LABEL base.image="rocker/r-ver:4.2.1" LABEL base.image="rocker/r-ver:4.2.1"
LABEL version="1" LABEL version="1"
LABEL software="ascii_alignment_pileup.R" LABEL software="ascii_alignment_pileup.R"
LABEL software.version="1.0.1" LABEL software.version=$version
LABEL software.description="Generates an ASCII-style pileup of read alignments in one or more BAM files against one or more regions specified in a BED file" LABEL software.description="Generates an ASCII-style pileup of read alignments in one or more BAM files against one or more regions specified in a BED file"
LABEL software.website="https://git.scicore.unibas.ch/zavolan_group/tools/ascii-alignment-pileup" LABEL software.website="https://git.scicore.unibas.ch/zavolan_group/tools/ascii-alignment-pileup"
LABEL software.documentation="https://git.scicore.unibas.ch/zavolan_group/tools/ascii-alignment-pileup" LABEL software.documentation="https://git.scicore.unibas.ch/zavolan_group/tools/ascii-alignment-pileup"
...@@ -64,4 +67,3 @@ WORKDIR ${WORKDIR} ...@@ -64,4 +67,3 @@ WORKDIR ${WORKDIR}
RUN chown -R ${USER}:${GROUP} ${WORKDIR} \ RUN chown -R ${USER}:${GROUP} ${WORKDIR} \
&& chmod 700 ${WORKDIR} && chmod 700 ${WORKDIR}
USER ${USER} USER ${USER}
...@@ -29,10 +29,11 @@ against one or more regions specified in a BED file.\n" ...@@ -29,10 +29,11 @@ against one or more regions specified in a BED file.\n"
author <- "Author: Alexander Kanitz" author <- "Author: Alexander Kanitz"
affiliation <- "Affiliation: Biozentrum, University of Basel" affiliation <- "Affiliation: Biozentrum, University of Basel"
email <- "Email: alexander.kanitz@alumni.ethz.ch" email <- "Email: alexander.kanitz@alumni.ethz.ch"
version <- "Version: 1.0.2" version <- "1.0.3"
version_formatted <- paste("Version:", version, sep=" ")
requirements <- c("optparse", "rtracklayer", "GenomicAlignments", "tools") requirements <- c("optparse", "rtracklayer", "GenomicAlignments", "tools")
requirements_txt <- paste("Requires:", paste(requirements, collapse=", "), sep=" ") requirements_txt <- paste("Requires:", paste(requirements, collapse=", "), sep=" ")
msg <- paste(description, author, affiliation, email, version, requirements_txt, sep="\n") msg <- paste(description, author, affiliation, email, version_formatted, requirements_txt, sep="\n")
notes <- "Notes: notes <- "Notes:
- For the input queries, consider the `--maximum-region-width` parameter, which - For the input queries, consider the `--maximum-region-width` parameter, which
is provided for safety. While it is possible to increase it, wide regions may is provided for safety. While it is possible to increase it, wide regions may
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment