summaryrefslogtreecommitdiff
path: root/grafana/Pkgfile
diff options
context:
space:
mode:
authorTim Biermann <tbier@posteo.de>2022-10-09 13:39:37 +0200
committerTim Biermann <tbier@posteo.de>2022-10-09 13:39:37 +0200
commit6ee642a8b75309cfbe1c2b889bb299a665fe4663 (patch)
tree1a819be7931ecc5dc393b715c4799dc8a68ec566 /grafana/Pkgfile
parent5c363ae3ea38536bc74687eb6292af3e07140ace (diff)
downloadcontrib-6ee642a8b75309cfbe1c2b889bb299a665fe4663.tar.gz
contrib-6ee642a8b75309cfbe1c2b889bb299a665fe4663.tar.xz
grafana: 9.1.6 -> 9.1.7; changed dependency: yarn -> yarn-gallium
Diffstat (limited to 'grafana/Pkgfile')
-rw-r--r--grafana/Pkgfile23
1 files changed, 16 insertions, 7 deletions
diff --git a/grafana/Pkgfile b/grafana/Pkgfile
index dd678661c..e7657ec31 100644
--- a/grafana/Pkgfile
+++ b/grafana/Pkgfile
@@ -1,10 +1,10 @@
# Description: The analytics platform for all your metrics
# URL: https://grafana.com/
# Maintainer: Tim Biermann, tbier at posteo dot de
-# Depends on: fontconfig go yarn
+# Depends on: fontconfig go yarn-gallium
name=grafana
-version=9.1.6
+version=9.1.7
release=1
source=(https://github.com/grafana/grafana/archive/v$version/$name-$version.tar.gz
https://dl.grafana.com/oss/release/grafana-$version.linux-amd64.tar.gz
@@ -20,6 +20,10 @@ build() {
mkdir "$PKGMK_SOURCE_DIR/gopath" || true
export GOPATH="$PKGMK_SOURCE_DIR/gopath"
+ export PKG_CONFIG_PATH="/usr/opt/nodejs-lts-gallium/lib/pkgconfig:$PKG_CONFIG_PATH"
+ export PKG_CONFIG_PATH="/usr/lib/openssl-1.1/pkgconfig:$PKG_CONFIG_PATH"
+ export PATH="/usr/opt/nodejs-lts-gallium/bin:$PATH"
+
cd $SRC/$name-$version
sed -ri 's,^(\s*data\s*=).*,\1 /var/lib/grafana,' conf/defaults.ini
@@ -27,15 +31,20 @@ build() {
sed -ri 's,^(\s*provisioning\s*=).*,\1 /var/lib/grafana/conf/provisioning,' conf/defaults.ini
sed -ri 's,^(\s*logs\s*=).*,\1 /var/log/grafana,' conf/defaults.ini
+ # backend
make gen-go
go run build.go setup
go run build.go build
- export NPM_CONFIG_PREFIX="$srcdir/npm"
- export PATH+=":$NPM_CONFIG_PREFIX/bin"
- export NODE_OPTIONS="--max-old-space-size=16000" # Increase to 8 GB
- yarn install
- NODE_ENV=production yarn run build
+ # frontend
+ export NPM_CONFIG_PREFIX="$SRC/npm"
+ export PATH="$NPM_CONFIG_PREFIX/bin:$PATH"
+ export NODE_OPTIONS="--max-old-space-size=16000"
+
+ /usr/opt/nodejs-lts-gallium/bin/yarn install
+ NODE_ENV=production /usr/opt/nodejs-lts-gallium/bin/yarn run build
+
+ # install
install -Dm644 $SRC/$name.confd $PKG/etc/conf.d/$name
install -Dsm755 bin/linux-amd64/grafana-server $PKG/usr/bin/grafana-server
install -Dsm755 bin/linux-amd64/grafana-cli $PKG/usr/bin/grafana-cli

Generated by cgit