mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-09-30 01:17:28 +03:00
grafana-agent: add passthru.updateScript
`nix-update` has support for `fetchYarnDeps` via the attribute name `offlineCache`. Our yarn FOD is called `frontendYarnOfflineCache`, which I find more descriptive and would like to keep this way. To work around this requirement, this adds an alias in `passthru`. The addition of `passthru.updateScript` also allows `nixpkgs-update` to update this package when the yarn FOD hash needs to be updated. See the following error from the last `nixpkgs-update` run: https://r.ryantm.com/log/grafana-agent/2024-02-27.log
This commit is contained in:
parent
35da8aa794
commit
6dd5c9ee3f
@ -2,10 +2,11 @@
|
||||
, buildGoModule
|
||||
, fetchFromGitHub
|
||||
, fetchYarnDeps
|
||||
, prefetch-yarn-deps
|
||||
, grafana-agent
|
||||
, nix-update-script
|
||||
, nixosTests
|
||||
, nodejs
|
||||
, prefetch-yarn-deps
|
||||
, stdenv
|
||||
, systemd
|
||||
, testers
|
||||
@ -89,13 +90,18 @@ buildGoModule rec {
|
||||
$out/bin/grafana-agent
|
||||
'';
|
||||
|
||||
passthru.tests = {
|
||||
inherit (nixosTests) grafana-agent;
|
||||
version = testers.testVersion {
|
||||
inherit version;
|
||||
command = "${lib.getExe grafana-agent} --version";
|
||||
package = grafana-agent;
|
||||
passthru = {
|
||||
tests = {
|
||||
inherit (nixosTests) grafana-agent;
|
||||
version = testers.testVersion {
|
||||
inherit version;
|
||||
command = "${lib.getExe grafana-agent} --version";
|
||||
package = grafana-agent;
|
||||
};
|
||||
};
|
||||
updateScript = nix-update-script { };
|
||||
# alias for nix-update to be able to find and update this attribute
|
||||
offlineCache = frontendYarnOfflineCache;
|
||||
};
|
||||
|
||||
meta = {
|
||||
|
Loading…
Reference in New Issue
Block a user