mirror of
https://github.com/ciromattia/kcc
synced 2025-12-13 17:56:30 +00:00
Overhauled Linux build environment
This commit is contained in:
26
Dockerfile
26
Dockerfile
@@ -1,26 +0,0 @@
|
|||||||
# Recipe used to build DEB package
|
|
||||||
|
|
||||||
FROM acidweb/kcc-base
|
|
||||||
MAINTAINER Paweł Jastrzębski <pawelj@iosphe.re>
|
|
||||||
|
|
||||||
ENV KCCVER 5.0.1
|
|
||||||
ADD . /app
|
|
||||||
|
|
||||||
RUN pip3 install pillow python-slugify psutil scandir pyinstaller
|
|
||||||
RUN gem install fpm
|
|
||||||
RUN useradd -ms /bin/bash kcc && chown -R kcc:kcc /app
|
|
||||||
|
|
||||||
USER kcc
|
|
||||||
WORKDIR /app
|
|
||||||
RUN pyinstaller -F -s --noupx kcc.py
|
|
||||||
RUN mkdir -p dist/usr/bin dist/usr/share/applications dist/usr/share/doc/kindlecomicconverter dist/usr/share/kindlecomicconverter dist/usr/share/lintian/overrides
|
|
||||||
RUN mv dist/kcc dist/usr/bin
|
|
||||||
RUN cp icons/comic2ebook.png dist/usr/share/kindlecomicconverter
|
|
||||||
RUN cp LICENSE.txt dist/usr/share/doc/kindlecomicconverter/copyright
|
|
||||||
RUN cp other/linux/kindlecomicconverter.desktop dist/usr/share/applications
|
|
||||||
RUN cp other/linux/kindlecomicconverter dist/usr/share/lintian/overrides
|
|
||||||
|
|
||||||
WORKDIR /app/dist
|
|
||||||
RUN fpm -f -s dir -t deb -n kindlecomicconverter -v $KCCVER -m "Paweł Jastrzębski <pawelj@iosphe.re>" --license "ISC" --description "Comic and Manga converter for e-book readers.\nThis app allows you to transform your PNG, JPG, GIF, CBZ, CBR and CB7 files\ninto EPUB or MOBI format e-books." --url "https://kcc.iosphe.re/" --deb-priority "optional" --vendor "" --category "graphics" -d "unrar | unrar-free" -d "p7zip-full" usr
|
|
||||||
|
|
||||||
CMD mkdir -p /out/dist && cp kindlecomicconverter_${KCCVER}_amd64.deb /out/dist
|
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
kindlecomicconverter: statically-linked-binary usr/bin/kcc
|
|
||||||
kindlecomicconverter: binary-without-manpage usr/bin/kcc
|
kindlecomicconverter: binary-without-manpage usr/bin/kcc
|
||||||
kindlecomicconverter: wrong-name-for-changelog-of-native-package usr/share/doc/kindlecomicconverter/changelog.Debian.gz
|
kindlecomicconverter: wrong-name-for-changelog-of-native-package usr/share/doc/kindlecomicconverter/changelog.Debian.gz
|
||||||
kindlecomicconverter: file-missing-in-md5sums usr/share/doc/kindlecomicconverter/changelog.Debian.gz
|
kindlecomicconverter: file-missing-in-md5sums usr/share/doc/kindlecomicconverter/changelog.Debian.gz
|
||||||
|
kindlecomicconverter: hardening-no-relro usr/bin/kcc
|
||||||
|
|||||||
3
setup.py
3
setup.py
@@ -90,8 +90,7 @@ class BuildBinaryCommand(distutils.cmd.Command):
|
|||||||
os.system("bash -c '%s'" % script)
|
os.system("bash -c '%s'" % script)
|
||||||
exit(0)
|
exit(0)
|
||||||
else:
|
else:
|
||||||
os.system('docker build --no-cache -t kcc . && docker run --rm -v ' + os.getcwd() +
|
os.system('docker run --rm -v ' + os.getcwd() + ':/app -e KCCVER=' + VERSION + ' acidweb/kcc')
|
||||||
':/out kcc && docker rmi kcc')
|
|
||||||
exit(0)
|
exit(0)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user