Skip to content

Commit

Permalink
- add support for custom config file (#24)
Browse files Browse the repository at this point in the history
- update to alloy v1.6.0
- release 0.1.2
  • Loading branch information
DanCech authored Jan 22, 2025
1 parent 02b1676 commit a123d58
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 5 deletions.
10 changes: 10 additions & 0 deletions grafana_cloud/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
<!-- https://developers.home-assistant.io/docs/add-ons/presentation#keeping-a-changelog -->

## 0.1.2

- Support providing custom config.alloy file
- Update to Alloy v1.6.0
- Update to addon base 3.21

## 0.1.1

- Update to Alloy v1.3.1

## 0.1.0

- Initial release
6 changes: 3 additions & 3 deletions grafana_cloud/build.yaml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
build_from:
amd64: "ghcr.io/home-assistant/amd64-base:3.20"
aarch64: "ghcr.io/home-assistant/aarch64-base:3.20"
amd64: "ghcr.io/home-assistant/amd64-base:3.21"
aarch64: "ghcr.io/home-assistant/aarch64-base:3.21"
labels:
org.opencontainers.image.title: "Home Assistant Add-on: Grafana Cloud"
org.opencontainers.image.description: "Grafana Cloud Addon."
org.opencontainers.image.source: "https://github.com/grafana/home-assistant-addons"
org.opencontainers.image.licenses: "Apache License 2.0"
org.opencontainers.image.vendor: "Grafana Labs"
args:
ALLOY_VERSION: "v1.3.1"
ALLOY_VERSION: "v1.6.0"
2 changes: 1 addition & 1 deletion grafana_cloud/config.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: "Grafana Cloud"
description: "Send metrics & logs to Grafana Cloud"
version: "0.1.1"
version: "0.1.2"
slug: "grafana_cloud"
init: false
arch:
Expand Down
7 changes: 6 additions & 1 deletion grafana_cloud/rootfs/etc/services.d/grafana_cloud/run
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,9 @@ export LOG_LEVEL=$(bashio::config 'log_level')
export SCRAPE_INTERVAL=$(bashio::config 'scrape_interval')
export ALLOY_DEPLOY_MODE=hass-addon-grafana-cloud

exec /usr/bin/grafana-alloy run --server.http.listen-addr=0.0.0.0:80 --storage.path=/config /config.alloy
CONFIG_FILE="/config.alloy"
if bashio::fs.file_exists "/config/config.alloy"; then
CONFIG_FILE="/config/config.alloy"
fi

exec /usr/bin/grafana-alloy run --server.http.listen-addr=0.0.0.0:80 --storage.path=/config $CONFIG_FILE

0 comments on commit a123d58

Please # to comment.