summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO15
-rw-r--r--PKGBUILD19
-rw-r--r--concordium-node-bin.install18
3 files changed, 52 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..39404c9753b3
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,15 @@
+pkgbase = concordium-node-bin
+ pkgdesc = Node for the Concordium blockchain
+ pkgver = 1.0.1
+ pkgrel = 1
+ url = https://github.com/Concordium/concordium-node
+ install = concordium-node-bin.install
+ arch = x86_64
+ license = AGPL3
+ depends = postgresql-libs
+ depends = openssl
+ depends = unbound
+ source = https://distribution.mainnet.concordium.software/deb/concordium-node_1.0.1-mainnet_amd64.deb
+ sha256sums = dcb76543e4fb0346242df1d8873bbdf89af6ccbd49ea6b4d315bd1dc4c14a135
+
+pkgname = concordium-node-bin
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..fdb5061ee0dc
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,19 @@
+# Maintainer: Martoko <mbastholm at gmail dot com>
+
+pkgname=concordium-node-bin
+pkgver=1.0.1
+pkgrel=1
+pkgdesc="Node for the Concordium blockchain"
+arch=('x86_64')
+url="https://github.com/Concordium/concordium-node"
+license=('AGPL3')
+depends=('postgresql-libs' 'openssl' 'unbound')
+install=concordium-node-bin.install
+source=("https://distribution.mainnet.concordium.software/deb/concordium-node_${pkgver}-mainnet_amd64.deb")
+sha256sums=('dcb76543e4fb0346242df1d8873bbdf89af6ccbd49ea6b4d315bd1dc4c14a135')
+
+package() {
+ tar xf data.tar.xz -C "${pkgdir}"
+ rm -r "${pkgdir}/usr/share" # Delete changelog.Debian.gz
+ mv "${pkgdir}/lib" "${pkgdir}/usr"
+}
diff --git a/concordium-node-bin.install b/concordium-node-bin.install
new file mode 100644
index 000000000000..8b102d206ed9
--- /dev/null
+++ b/concordium-node-bin.install
@@ -0,0 +1,18 @@
+post_install() {
+ # Only update the node name if the override configuration does not already exist.
+ # This is not perfect, since we don't know whether the override contains
+ # COLLECTOR_NODE_NAME, but it is good enough for now.
+ override_path=/etc/systemd/system/concordium-node-collector.service.d/override.conf
+ if [[ ! -f $override_path ]]; then
+ echo "Writing default node name ($(hostname)) to '${override_path}'."
+ echo "Please update the file with a node name of your choosing."
+ mkdir -p /etc/systemd/system/concordium-node-collector.service.d/
+ cat > /etc/systemd/system/concordium-node-collector.service.d/override.conf <<EOF
+[Service]
+Environment='COLLECTOR_NODE_NAME=`systemd-escape "$(hostname)"`'
+EOF
+ else
+ echo "Node collector override file '${override_path}' already exists."
+ echo "To update settings edit the file."
+ fi
+}