aboutsummaryrefslogtreecommitdiff
path: root/bin/mc
diff options
context:
space:
mode:
authorTrygve Laugstøl <trygvis@inamo.no>2021-01-20 10:29:19 +0100
committerTrygve Laugstøl <trygvis@inamo.no>2021-01-20 10:29:19 +0100
commitd77a2af7acee55457f4cab5f3acc8e3060564196 (patch)
treee4c3ffc2af288b7f5b6e1aadc93a147075bb1832 /bin/mc
parented65919b0327e733c6863d397ba354badf2a280e (diff)
downloadinfra-d77a2af7acee55457f4cab5f3acc8e3060564196.tar.gz
infra-d77a2af7acee55457f4cab5f3acc8e3060564196.tar.bz2
infra-d77a2af7acee55457f4cab5f3acc8e3060564196.tar.xz
infra-d77a2af7acee55457f4cab5f3acc8e3060564196.zip
Minio + wal-g
Diffstat (limited to 'bin/mc')
-rwxr-xr-xbin/mc19
1 files changed, 19 insertions, 0 deletions
diff --git a/bin/mc b/bin/mc
new file mode 100755
index 0000000..0f84a63
--- /dev/null
+++ b/bin/mc
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+set -euo pipefail
+
+v=RELEASE.2021-01-05T05-03-58Z
+basedir=$(dirname $0)
+
+mc="$basedir/.mc/mc.$v"
+
+mkdir -p "$(dirname $mc)"
+
+if [[ ! -x $mc ]]
+then
+ wget -O "$mc" https://dl.min.io/client/mc/release/linux-amd64/archive/mc.$v
+ chmod +x "$mc"
+ ln -s mc.$v "$basedir/.mc/mc"
+fi
+
+exec "$basedir/.mc/mc" "${@}"