ci: generate golangci.yml with correct CEPH_VERSION

When building against go-ceph, the most recent version of Ceph is
assumed to be available (currently Octopus). In case an older version of
the development packages is installed, building go-ceph will fail.

Golangci-lint does not accept the `-tags nautilus` parameter like other
Golang tools. Instead, the build-constraints need to be configured in a
confguration file.

This change takes care of the following:
- move the current scripts/golangci.yml to a template
- add the @@CEPH_VERSION@@ substitute
- generate the configuration file when needed

Signed-off-by: Niels de Vos <ndevos@redhat.com>
This commit is contained in:
Niels de Vos
2020-07-02 14:05:42 +02:00
committed by mergify[bot]
parent 7a87db39e6
commit f9f9fba26c
3 changed files with 11 additions and 1 deletions

View File

@ -5,6 +5,9 @@
# options for analysis running
run:
build-tags:
- @@CEPH_VERSION@@
# default concurrency is a available CPU number
concurrency: 4