Go to file
Aaron Fischer 17d8fc8ea6 Make this project a LOT simpler 2021-03-10 00:52:59 +01:00
public Update 'public/book.html' 2021-03-09 23:47:52 +01:00
src/buchdesmonats Make this project a LOT simpler 2021-03-10 00:52:59 +01:00
.gitignore Make source configurable (support comics and more!) 2020-11-02 10:30:12 +01:00
AUTHOR.mkd Rearrange the README files 2015-06-09 09:56:51 +02:00
BOOK.mkd ULR fix 05/2016 2021-03-04 21:22:29 +01:00
COMIC.mkd update 3/2021 und EAN-Link Ergänzung 2021-03-02 18:14:48 +01:00
Dockerfile Add multi stage dockerfile and fix source URL 2021-02-18 02:00:03 +01:00
LICENSE.mkd Rearrange the README files 2015-06-09 09:56:51 +02:00
README.mkd Make this project a LOT simpler 2021-03-10 00:52:59 +01:00
project.clj Change cover fetching logic to a MUCH simpler one 2021-03-04 21:00:42 +01:00

README.mkd

Buch des Monats

This simple script generate a HTML representation of the "Book of the Month" list. This includes books and comics.

Building

$ lein uberjar

Usage

$ java -jar target/buchdesmonats-2.0-standalone.jar [book|comic]

Docker

You can use the Dockerfile to generate the static content. This is useful for a cronjob. You want to mount the target dir, so it is not lost after the container stops. The Dockerfile is a multi stage dockerfile, which first compiles the clojure files into a standalone jar file and then use it to generate the book of the month content.

$ docker build . -t bdm:latest

Run this periodically:

$ docker run -it -v "$PWD/public:/app/public" -e "TYPE=book" bdm:latest
$ docker run -it -v "$PWD/public:/app/public" -e "TYPE=comic" bdm:latest

If you want to run this in a cronjob, remove the -t from the docker run command, because we do not have a tty.

Update

$ git revert .
$ git pull
$ docker build . t bdm:latest

Keep in mind that the git revert . is needed because the bdm.jar file itself will manipulate some of the templates in public/ which will be conflicted with the version in git.

Authors