summaryrefslogtreecommitdiffstats
path: root/tests/Dockerfile.centos
blob: 06013ee6279d00e9ca2f761cd6f7a036b1f80b8c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
FROM centos:centos7
RUN yum install -y rpm-build yum-utils
WORKDIR /src
COPY mod_authnz_pam.spec .
RUN yum-builddep -y mod_authnz_pam.spec
COPY * source/
RUN rpm -q --qf '%{name}-%{version}\n' --specfile mod_authnz_pam.spec | head -1 > name_version
RUN mv -v source $( cat name_version )
RUN mkdir -p ~/rpmbuild/SOURCES
RUN tar cvzf ~/rpmbuild/SOURCES/$( cat name_version ).tar.gz $( cat name_version )
RUN rpmbuild -bb --define "dist $( rpm --eval '%{dist}' ).localbuild" mod_authnz_pam.spec
RUN yum install -y ~/rpmbuild/RPMS/*/$( cat name_version )-*.localbuild.*.rpm