Merged update from upstream sources

This is an automated DistroBaker update from upstream sources.
If you do not know what this is about or would like to opt out,
contact the OSCI team.

Source: https://src.fedoraproject.org/rpms/grafana.git#093c901afa6e6e303e75538944936b96f754133a
This commit is contained in:
DistroBaker 2021-01-22 12:38:42 +00:00
parent 69a6f71052
commit 2b2f0a6d03
3 changed files with 9 additions and 3 deletions

View File

@ -32,14 +32,16 @@ index 9cad151c0d..a786edc596 100755
if [ -f "$DEFAULT" ]; then
. "$DEFAULT"
fi
@@ -36,4 +38,11 @@ OPTS="--homepath=${GRAFANA_HOME} \
@@ -36,4 +38,13 @@ OPTS="--homepath=${GRAFANA_HOME} \
cfg:default.paths.logs=${LOG_DIR} \
cfg:default.paths.plugins=${PLUGINS_DIR}'"
-eval $EXECUTABLE "$OPTS" "$@"
+if [ "$(id -u)" -eq 0 ]; then
+ cd "${GRAFANA_HOME}"
+ exec runuser -u "${GRAFANA_USER}" -- "$EXECUTABLE" "$OPTS" "$@"
+elif [ "$(id -u -n)" = "${GRAFANA_USER}" ]; then
+ cd "${GRAFANA_HOME}"
+ exec "$EXECUTABLE" "$OPTS" "$@"
+else
+ echo "Please run this script as user \"${GRAFANA_USER}\" or root."

View File

@ -769,7 +769,7 @@ disable_sanitize_html = false
enable_alpha = false
app_tls_skip_verify_insecure = false
# Enter a comma-separated list of plugin identifiers to identify plugins that are allowed to be loaded even if they lack a valid signature.
allow_loading_unsigned_plugins =
allow_loading_unsigned_plugins = pcp-redis-datasource
marketplace_url = https://grafana.com/grafana/plugins/
#################################### Grafana Image Renderer Plugin ##########################

View File

@ -23,7 +23,7 @@ end}
Name: grafana
Version: 7.3.6
Release: 1%{?dist}
Release: 2%{?dist}
Summary: Metrics dashboard and graph editor
License: ASL 2.0
URL: https://grafana.org
@ -623,6 +623,10 @@ export TZ=GMT
%changelog
* Fri Jan 22 2021 Andreas Gerstmayr <agerstmayr@redhat.com> 7.3.6-2
- change working dir to $GRAFANA_HOME in grafana-cli wrapper (fixes Red Hat BZ #1916083)
- add pcp-redis-datasource to allow_loading_unsigned_plugins config option
* Mon Dec 21 2020 Andreas Gerstmayr <agerstmayr@redhat.com> 7.3.6-1
- update to 7.3.6 tagged upstream community sources, see CHANGELOG
- remove dependency on SAML (not supported in the open source version of Grafana)