fortune:1.0.0 - Docker-Image with Fortune
authorKai Moritz <kai@juplo.de>
Wed, 1 Sep 2021 20:51:08 +0000 (22:51 +0200)
committerKai Moritz <kai@juplo.de>
Sat, 4 Sep 2021 22:25:58 +0000 (00:25 +0200)
.dockerignore [new file with mode: 0644]
.gitignore [new file with mode: 0644]
Dockerfile [new file with mode: 0644]
README.sh [new file with mode: 0755]

diff --git a/.dockerignore b/.dockerignore
new file mode 100644 (file)
index 0000000..c6fd883
--- /dev/null
@@ -0,0 +1,2 @@
+*
+!fortune-simpsons-chalkboard/chalkboard*
diff --git a/.gitignore b/.gitignore
new file mode 100644 (file)
index 0000000..efb0543
--- /dev/null
@@ -0,0 +1 @@
+fortune-simpsons-chalkboard*
diff --git a/Dockerfile b/Dockerfile
new file mode 100644 (file)
index 0000000..fd3d7d1
--- /dev/null
@@ -0,0 +1,7 @@
+FROM ubuntu:21.04
+
+RUN apt-get update && apt-get install -y fortune fortunes-mario fortunes-off fortunes-spam fortunes-ubuntu-server fortunes-debian-hints fortunes-de fortune-anarchism httpie && apt-get clean && rm -rvf /var/lib/apt/lists/*
+RUN date > builddate.txt
+COPY fortune-simpsons-chalkboard/chalkboard* /usr/share/games/fortunes/
+
+CMD ["/usr/games/fortune"]
diff --git a/README.sh b/README.sh
new file mode 100755 (executable)
index 0000000..dab0030
--- /dev/null
+++ b/README.sh
@@ -0,0 +1,15 @@
+#!/bin/sh
+
+if [ "$1" = "" ]
+then
+  FORTUNE=juplo/fortune
+else
+  FORTUNE="$1"
+fi
+echo "Downloading Chalkboard-Quotes from Bart Simpson..."
+curl https://www.splitbrain.org/_media/projects/fortunes/fortune-simpsons-chalkboard.tgz > fortune-simpsons-chalkboard.tgz
+echo "Unpacking Chalkboard-Quotes..."
+tar -xzvf fortune-simpsons-chalkboard.tgz
+
+echo "Building the image $FORTUNE"
+docker build -t $FORTUNE .