From fbca4983a5b8bfdf975ad402525eea31b44e6bc7 Mon Sep 17 00:00:00 2001 From: Klaus Hartl Date: Sat, 18 Sep 2021 08:22:25 +0200 Subject: [PATCH] Setup container to run talisman Mimicing a pre-push hook, where refs and shas need to passed in as arguments. --- Dockerfile | 8 ++++++++ entrypoint.sh | 5 +++++ 2 files changed, 13 insertions(+) create mode 100644 Dockerfile create mode 100755 entrypoint.sh diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..482e1dc --- /dev/null +++ b/Dockerfile @@ -0,0 +1,8 @@ +FROM alpine:3.13.6 + +ADD ["https://github.com/thoughtworks/talisman/releases/download/v1.22.0/talisman_linux_amd64", "/talisman"] +RUN chmod +x /talisman + +COPY entrypoint.sh /entrypoint.sh + +ENTRYPOINT ["/entrypoint.sh"] diff --git a/entrypoint.sh b/entrypoint.sh new file mode 100755 index 0000000..d359208 --- /dev/null +++ b/entrypoint.sh @@ -0,0 +1,5 @@ +#!/bin/sh -l + +set -e + +sh -c "echo $* | /talisman"