2021-05-02 17:53:38 +00:00
|
|
|
|
{ lib, fetchFromGitHub, buildGoModule }:
|
|
|
|
|
|
|
|
|
|
buildGoModule rec {
|
|
|
|
|
pname = "goss";
|
2023-09-04 10:27:46 +00:00
|
|
|
|
|
|
|
|
|
# Don't forget to update dgoss to the same version.
|
|
|
|
|
version = "0.4.1";
|
2021-05-02 17:53:38 +00:00
|
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
2023-09-04 10:27:46 +00:00
|
|
|
|
owner = "goss-org";
|
2021-05-02 17:53:38 +00:00
|
|
|
|
repo = pname;
|
2023-09-04 10:27:46 +00:00
|
|
|
|
rev = "refs/tags/v${version}";
|
|
|
|
|
hash = "sha256-dpMTUBMEG5tDi7E6ZRg1KHqIj5qDlvwfwJEgq/5z7RE=";
|
2021-05-02 17:53:38 +00:00
|
|
|
|
};
|
|
|
|
|
|
2023-09-04 10:27:46 +00:00
|
|
|
|
vendorHash = "sha256-n+k7f9e2iqf4KrcDkzX0CWk+Bq2WE3dyUEid4PTP1FA=";
|
2021-05-02 17:53:38 +00:00
|
|
|
|
|
|
|
|
|
CGO_ENABLED = 0;
|
2021-08-21 08:23:49 +00:00
|
|
|
|
ldflags = [
|
|
|
|
|
"-s" "-w" "-X main.version=v${version}"
|
|
|
|
|
];
|
2021-05-02 17:53:38 +00:00
|
|
|
|
|
2023-09-04 10:27:46 +00:00
|
|
|
|
checkFlags = [
|
|
|
|
|
# Prometheus tests are skipped upstream
|
|
|
|
|
# See https://github.com/goss-org/goss/blob/master/ci/go-test.sh
|
|
|
|
|
"-skip" "^TestPrometheus"
|
|
|
|
|
];
|
|
|
|
|
|
2021-05-02 17:53:38 +00:00
|
|
|
|
meta = with lib; {
|
2023-09-04 10:27:46 +00:00
|
|
|
|
homepage = "https://github.com/goss-org/goss/";
|
|
|
|
|
changelog = "https://github.com/goss-org/goss/releases/tag/v${version}";
|
2021-05-02 17:53:38 +00:00
|
|
|
|
description = "Quick and easy server validation";
|
|
|
|
|
longDescription = ''
|
|
|
|
|
Goss is a YAML based serverspec alternative tool for validating a server’s configuration.
|
|
|
|
|
It eases the process of writing tests by allowing the user to generate tests from the current system state.
|
|
|
|
|
Once the test suite is written they can be executed, waited-on, or served as a health endpoint.
|
|
|
|
|
'';
|
|
|
|
|
license = licenses.asl20;
|
|
|
|
|
platforms = platforms.linux;
|
|
|
|
|
maintainers = with maintainers; [ hyzual jk ];
|
|
|
|
|
};
|
|
|
|
|
}
|