Skip to content

Commit ad88f9a

Browse files
committed
Added: packaging scripts for docker and FPM (centos 7).
#84
1 parent 7e8c5b3 commit ad88f9a

File tree

2 files changed

+20
-0
lines changed

2 files changed

+20
-0
lines changed

packaging/centos-7/Dockerfile

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
FROM centos:latest
2+
3+
4+
MAINTAINER Oleg Strizhechenko version: 0.1
5+
6+
RUN yum -y install epel-release && yum -y update
7+
RUN yum -y install ruby-devel gcc make rpm-build rubygems python-pip
8+
RUN gem install --no-ri --no-rdoc fpm
9+
ADD netutils.sh /root/netutils.sh
10+
RUN pip install setuptools
11+
12+
CMD ["/bin/bash"]

packaging/centos-7/netutils.sh

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
#!/usr/bin/env bash
2+
3+
IFS=: read _ _ distro _ release _ < /etc/system-release-cpe
4+
if [ "$distro" != "centos" ]; then
5+
echo "Script written to run in CentOS, not $distro"
6+
fi
7+
8+
fpm -s python -t rpm -d PyYAML --python-disable-dependency pyyaml --rpm-dist "el$release" netutils-linux

0 commit comments

Comments
 (0)