Commit 780c7b4f authored by Daniel Brown's avatar Daniel Brown

Finishing up Debian binary package

parent 9c84efda
......@@ -6,4 +6,4 @@ RUN apt --assume-yes update
RUN apt --assume-yes install gcc git libgsl-dev make g++ python
RUN git clone
#CMD ["python", "/host/"]
\ No newline at end of file
CMD ["python", "/host/"]
\ No newline at end of file
Builds an Debian package for the Finesse binary
Build docker image first:
docker build -t finesse/debian .
To create the rpm package:
docker run -it --volume=${PWD}:/host finesse/debian
This will build Finesse on the Docker image and an deb file will be returned in this folder.
\ No newline at end of file
......@@ -14,27 +14,32 @@ os.chdir("/root/finesse")
call("git pull".split())
git_describe = str(check_output('git describe --tags'.split())).split("-")
call("./ --build".split())
call("mkdir -p finesse/DEBIAN".split())
# e.g. Finesse 2.2 (2.2-18-g4e88fe48), 29.05.2018
git_describe = str(check_output('/root/finesse/kat -v'.split()))
version = git_describe.split()[2].strip('(').strip(')').split('-')
vals = {
"version": git_describe[0],
"release": git_describe[1],
"version": version[0],
"release": version[1],
call('mkdir -p finesse/DEBIAN'.format(**vals).split())
call('mkdir -p finesse/usr/bin'.format(**vals).split())
call('mkdir -p finesse/etc/finesse'.format(**vals).split())
call('cp /root/finesse/kat /root/finesse/packaging/deb/finesse/usr/bin'.format(**vals).split())
call('cp /root/finesse/kat.ini /root/finesse/packaging/deb/finesse/etc/finesse'.format(**vals).split())
call('tar -zcvf ./SOURCES/finesse-{version}-{release}.tar.gz finesse-{version}/'.format(**vals).split())
with open("/root/finesse/packaging/deb/finesse/DEBIAN/control", "w") as f:
s = string.Formatter().vformat(textwrap.dedent("""
Package: finesse
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment