Skip to content

Commit bc36a60

Browse files
authored
Refactor (#6306)
1 parent d4c59ca commit bc36a60

2 files changed

Lines changed: 7 additions & 6 deletions

File tree

ct/grafana.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ function update_script() {
2727
msg_error "No ${APP} Installation Found!"
2828
exit
2929
fi
30+
3031
msg_info "Updating ${APP}"
3132
$STD apt-get update
3233
$STD apt-get -y upgrade
@@ -41,4 +42,4 @@ description
4142
msg_ok "Completed Successfully!\n"
4243
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
4344
echo -e "${INFO}${YW} Access it using the following URL:${CL}"
44-
echo -e "${TAB}${GATEWAY}${BGN}http://${IP}:3000${CL}"
45+
echo -e "${TAB}${GATEWAY}${BGN}http://${IP}:3000${CL}"

install/grafana-install.sh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,20 +14,20 @@ network_check
1414
update_os
1515

1616
msg_info "Installing Dependencies"
17-
$STD apt-get install -y apt-transport-https
18-
$STD apt-get install -y software-properties-common
17+
$STD apt-get install -y \
18+
apt-transport-https \
19+
software-properties-common
1920
msg_ok "Installed Dependencies"
2021

2122
msg_info "Setting up Grafana Repository"
2223
curl -fsSL "https://apt.grafana.com/gpg.key" -o "/usr/share/keyrings/grafana.key"
23-
sh -c 'echo "deb [signed-by=/usr/share/keyrings/grafana.key] https://apt.grafana.com stable main" > /etc/apt/sources.list.d/grafana.list'
24+
echo "deb [signed-by=/usr/share/keyrings/grafana.key] https://apt.grafana.com stable main" >/etc/apt/sources.list.d/grafana.list
2425
msg_ok "Set up Grafana Repository"
2526

2627
msg_info "Installing Grafana"
2728
$STD apt-get update
2829
$STD apt-get install -y grafana
29-
systemctl start grafana-server
30-
systemctl enable --now -q grafana-server.service
30+
systemctl enable -q --now grafana-server
3131
msg_ok "Installed Grafana"
3232

3333
motd_ssh

0 commit comments

Comments
 (0)