Skip to content

Commit

Permalink
add dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
guyzsarun committed Aug 9, 2023
1 parent 1017d2a commit 4811a5d
Show file tree
Hide file tree
Showing 3 changed files with 48 additions and 0 deletions.
6 changes: 6 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
build
CMakeFiles
tests/**/*.pyc
.github
.pytest_cache
*.tar.gz
26 changes: 26 additions & 0 deletions docker/Dockerfile.base
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
FROM almalinux:8
MAINTAINER Sarun Nuntaviriyakul <[email protected]>
LABEL org.opencontainers.image.source https://github.com/guyzsarun/xrootd-cmsjson

WORKDIR /xrootd

RUN yum -y update && \
yum install -y dnf \
https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm \
https://repo.opensciencegrid.org/osg/3.6/osg-3.6-el8-release-latest.rpm \
epel-release

RUN dnf group install -y "Development Tools"

# CMS json dependency
RUN yum install -y cmake \
wget \
xrootd \
python3-devel \
python3-xrootd \
xrootd-devel \
pcre-devel \
xerces-c-devel \
xrootd-devel \
https://cbs.centos.org/kojifiles/packages/jsoncpp/1.9.4/4.el8s/x86_64/jsoncpp-1.9.4-4.el8s.x86_64.rpm \
https://cbs.centos.org/kojifiles/packages/jsoncpp/1.9.4/4.el8s/x86_64/jsoncpp-devel-1.9.4-4.el8s.x86_64.rpm
16 changes: 16 additions & 0 deletions docker/Dockerfile.test
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
ARG base_img
FROM $base_img

MAINTAINER Sarun Nuntaviriyakul <[email protected]>
LABEL org.opencontainers.image.source https://github.com/guyzsarun/xrootd-cmsjson

RUN pip3 install pytest

COPY . .

RUN mkdir -p build
RUN cd build && \
cmake .. -DBUILD_TEST=true && \
make && \
make install

0 comments on commit 4811a5d

Please sign in to comment.