deb/repo-add-elastic.bash
changeset 1 f497bf96ddc3
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/deb/repo-add-elastic.bash	Sat Mar 18 19:19:24 2023 +0200
@@ -0,0 +1,15 @@
+#!/bin/bash
+
+set -e
+src=elastic
+
+cmd="curl -o /usr/share/keyrings/$src.asc https://artifacts.elastic.co/GPG-KEY-elasticsearch"
+eval $cmd
+
+cat <<EOF >/etc/apt/sources.list.d/$src.list
+# https://www.elastic.co/guide/en/elasticsearch/reference/current/deb.html
+# For new GPG key use:
+#   $cmd
+
+deb [arch=amd64 signed-by=/usr/share/keyrings/$src.asc] https://artifacts.elastic.co/packages/8.x/apt stable main
+EOF