Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
nexpie-grafana-theme
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Registry
Registry
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kornkitt Poolsup
nexpie-grafana-theme
Commits
50bc801f
Commit
50bc801f
authored
Dec 06, 2017
by
bergquist
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dashboards as cfg: copy dash/ds files if missing
parent
361acd3f
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
4 deletions
+8
-4
packaging/deb/control/postinst
+4
-2
packaging/rpm/control/postinst
+4
-2
No files found.
packaging/deb/control/postinst
View file @
50bc801f
...
@@ -29,10 +29,12 @@ case "$1" in
...
@@ -29,10 +29,12 @@ case "$1" in
if
[
!
-f
$CONF_FILE
]
;
then
if
[
!
-f
$CONF_FILE
]
;
then
cp /usr/share/grafana/conf/sample.ini
$CONF_FILE
cp /usr/share/grafana/conf/sample.ini
$CONF_FILE
cp /usr/share/grafana/conf/ldap.toml /etc/grafana/ldap.toml
cp /usr/share/grafana/conf/ldap.toml /etc/grafana/ldap.toml
fi
if
[
!
-f
$DATASOURCES_CFG_DIR
]
;
then
mkdir
-p
/etc/grafana/dashboards /etc/grafana/datasources
mkdir
-p
/etc/grafana/dashboards /etc/grafana/datasources
cp /usr/share/grafana/conf/dashboards/sample.yaml
/etc/grafana/dashboards
/sample.yaml
cp /usr/share/grafana/conf/dashboards/sample.yaml
$DASHBOARDS_CFG_DIR
/sample.yaml
cp /usr/share/grafana/conf/datasources/sample.yaml
/etc/grafana/datasources
/sample.yaml
cp /usr/share/grafana/conf/datasources/sample.yaml
$DATASOURCES_CFG_DIR
/sample.yaml
fi
fi
# configuration files should not be modifiable by grafana user, as this can be a security issue
# configuration files should not be modifiable by grafana user, as this can be a security issue
...
...
packaging/rpm/control/postinst
View file @
50bc801f
...
@@ -43,10 +43,12 @@ if [ $1 -eq 1 ] ; then
...
@@ -43,10 +43,12 @@ if [ $1 -eq 1 ] ; then
if
[
!
-f
$CONF_FILE
]
;
then
if
[
!
-f
$CONF_FILE
]
;
then
cp /usr/share/grafana/conf/sample.ini
$CONF_FILE
cp /usr/share/grafana/conf/sample.ini
$CONF_FILE
cp /usr/share/grafana/conf/ldap.toml /etc/grafana/ldap.toml
cp /usr/share/grafana/conf/ldap.toml /etc/grafana/ldap.toml
fi
if
[
!
-f
$DATASOURCES_CFG_DIR
]
;
then
mkdir
-p
/etc/grafana/dashboards /etc/grafana/datasources
mkdir
-p
/etc/grafana/dashboards /etc/grafana/datasources
cp /usr/share/grafana/conf/dashboards/sample.yaml
/etc/grafana/dashboards
/sample.yaml
cp /usr/share/grafana/conf/dashboards/sample.yaml
$DASHBOARDS_CFG_DIR
/sample.yaml
cp /usr/share/grafana/conf/datasources/sample.yaml
/etc/grafana/datasources
/sample.yaml
cp /usr/share/grafana/conf/datasources/sample.yaml
$DATASOURCES_CFG_DIR
/sample.yaml
fi
fi
# Set user permissions on /var/log/grafana, /var/lib/grafana
# Set user permissions on /var/log/grafana, /var/lib/grafana
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment