Commit Graph

258 Commits

Author SHA1 Message Date
N
6951f9f482
Merge pull request #69 from noelmcloughlin/onchange
fix(indempotency): run reload onchanges only
2021-08-06 10:59:34 +01:00
Imran Iqbal
3fafc2172e
ci(gemfile+lock): use ssf customised inspec repo [skip ci]
* Automated using https://github.com/myii/ssf-formula/pull/357
2021-08-04 21:56:04 +01:00
Imran Iqbal
bd213f2ddf
chore(gemfile.lock): update to latest gem versions (2021-W31) [skip ci]
* Automated using https://github.com/myii/ssf-formula/pull/356
2021-08-04 21:38:49 +01:00
Imran Iqbal
1b94b086c1
chore(gemfile.lock): update to latest gem versions (2021-W30) [skip ci]
* Automated using https://github.com/myii/ssf-formula/pull/353
2021-07-26 14:30:13 +01:00
Imran Iqbal
33fbb956cd
chore(gemfile.lock): update to latest gem versions (2021-W29) [skip ci]
* Automated using https://github.com/myii/ssf-formula/pull/349
2021-07-21 18:32:58 +01:00
Imran Iqbal
802970c47d
ci: add Debian 11 Bullseye & update yamllint configuration [skip ci]
* Automated using https://github.com/myii/ssf-formula/pull/345
2021-07-18 19:04:28 +01:00
Imran Iqbal
0e65cc345b
feat(config/users): add support for debian-11 [skip ci]
Avoid this failure when installing the package:

```
Setting up prometheus (2.24.1+ds-1+b5) ...
adduser: The user `prometheus' already exists, but is not a system user. Exiting.
dpkg: error processing package prometheus (--configure):
 installed prometheus package post-installation script subprocess returned error exit status 1
Errors were encountered while processing:
 prometheus
```
2021-07-18 14:42:35 +01:00
Imran Iqbal
32039539bb
ci(kitchen): move provisioner block & update run_command [skip ci]
* Automated using https://github.com/myii/ssf-formula/pull/344
2021-07-17 21:12:00 +01:00
Imran Iqbal
7ddcd607f6
chore(gemfile+lock): update to latest gem versions (2021-W28) [skip ci]
* Automated using https://github.com/myii/ssf-formula/pull/343
2021-07-17 20:29:21 +01:00
semantic-release-bot
4bd140d71b chore(release): 5.5.2 [skip ci]
## [5.5.2](https://github.com/saltstack-formulas/prometheus-formula/compare/v5.5.1...v5.5.2) (2021-07-16)

### Bug Fixes

* **clientlibs/install:** ensure tar is available for Amazon Linux 2 ([7140ccf](7140ccf8a8))
* check for Amazon in osfamilymap for pkg repo ([338ab4d](338ab4ddb6)), closes [#65](https://github.com/saltstack-formulas/prometheus-formula/issues/65)
* update Gitlab CI -test amazonlinux correctly ([6745bf2](6745bf23d4)), closes [#65](https://github.com/saltstack-formulas/prometheus-formula/issues/65)
2021-07-16 02:50:20 +00:00
Imran Iqbal
f9c4e46282
Merge pull request #67 from mdschmitt/master
Check for Amazon in osfamilymap to create pkg repo
2021-07-16 03:39:19 +01:00
Michael Schmitt
7140ccf8a8
fix(clientlibs/install): ensure tar is available for Amazon Linux 2 2021-07-15 20:23:21 -06:00
Michael Schmitt
6745bf23d4
fix: update Gitlab CI -test amazonlinux correctly
* this change sets things to test both the default and repo suites for Amazon Linux.

Resolves #65
2021-07-15 17:56:23 -06:00
Michael Schmitt
338ab4ddb6
fix: check for Amazon in osfamilymap for pkg repo
* Add check for Amazon Linux to osfamilymap.yaml so that the RPM package repository is properly generated.

Resolves #65
2021-07-15 02:17:59 -06:00
noelmcloughlin
9166498fd8 fix(indempotency): run reload onchanges only 2021-07-15 09:13:17 +01:00
Imran Iqbal
2c572d0019
chore(deps): bump addressable from 2.7.0 to 2.8.0 [skip ci]
* Automated using https://github.com/myii/ssf-formula/pull/340
2021-07-14 12:15:49 +01:00
semantic-release-bot
8e9616208c chore(release): 5.5.1 [skip ci]
## [5.5.1](https://github.com/saltstack-formulas/prometheus-formula/compare/v5.5.0...v5.5.1) (2021-07-09)

### Bug Fixes

* added guidance and reverted incorrected changes from prior commits ([0ca247a](0ca247a37e)), closes [#59](https://github.com/saltstack-formulas/prometheus-formula/issues/59)
* added guidance and reverted incorrected changes from prior commits ([a4dfb87](a4dfb87554)), closes [#59](https://github.com/saltstack-formulas/prometheus-formula/issues/59)
* added handle for alternative argument opts header ([076869a](076869a8cd)), closes [#59](https://github.com/saltstack-formulas/prometheus-formula/issues/59)
* added handle for alternative argument opts header ([4de3ebd](4de3ebd241)), closes [#59](https://github.com/saltstack-formulas/prometheus-formula/issues/59)
* removed erroneus dash (-) ([ef8a3a9](ef8a3a9ad7)), closes [#59](https://github.com/saltstack-formulas/prometheus-formula/issues/59)
* removed erroneus dash (-) ([52845bb](52845bb534)), closes [#59](https://github.com/saltstack-formulas/prometheus-formula/issues/59)
* revert to use of macro.jinja for arg handling ([f2261f9](f2261f9dc9))
* revert to use of macro.jinja for arg handling ([696bee0](696bee0522))
* rework to implement environment variables handling ([e52f804](e52f804bf4)), closes [#59](https://github.com/saltstack-formulas/prometheus-formula/issues/59)
* rework to implement environment variables handling ([eea5b40](eea5b407fa)), closes [#59](https://github.com/saltstack-formulas/prometheus-formula/issues/59) [#59](https://github.com/saltstack-formulas/prometheus-formula/issues/59)
* switched test config entry that wasnt available for deb9 ([5c1d8b6](5c1d8b6870))
* switched test config entry that wasnt available for deb9 ([4635ca7](4635ca7070))

### Continuous Integration

* **3003.1:** update inc. AlmaLinux, Rocky & `rst-lint` [skip ci] ([5550397](55503974e4))
* **kitchen+gitlab:** remove Ubuntu 16.04 & Fedora 32 (EOL) [skip ci] ([fa96aab](fa96aabba7))
2021-07-09 23:37:57 +00:00
N
f51d24563d
Merge pull request #60 from B1ue-W01f/fix/environ_correction
Fix/environ correction
2021-07-10 00:28:37 +01:00
Imran Iqbal
55503974e4
ci(3003.1): update inc. AlmaLinux, Rocky & rst-lint [skip ci]
* Automated using https://github.com/myii/ssf-formula/pull/335
2021-07-02 00:06:56 +01:00
BlueWolf
d9b2af894a Merge branch 'fix/environ_correction' of https://github.com/B1ue-W01f/prometheus-formula into fix/environ_correction 2021-06-30 05:19:45 +01:00
BlueWolf
ef8a3a9ad7 fix: removed erroneus dash (-)
Dash was incorrectly left alongside squid_exporter entry in
osfamilymap.

Resolves: #59
2021-06-30 05:19:08 +01:00
BlueWolf
076869a8cd fix: added handle for alternative argument opts header
Centos and oraclelinux repositories for prometheus include bespoke headers
in the environment files (e.g. Debian: ARGS=, Centos: PROMETHEUS_OPTS=
ALERTMANAGER_OPTS=). This has been added as a default pillar with osmap
variances.
Additionally archlinux repo install was failing so added basic support -
an issue still remains for the prometheus app itself due to the service
file included in the arch repo hardcoding some config options - resulting
in the possibility to duplicate arguments resulting in a service error.
The prometheus service currently does not start due to permissions not being
applied to a data folder. The added config.storage begins to solve this and
ensures alignment on all platforms but would result in a duplicate config
entry as above. Prometheus on arch therefore needs more work but the exporter
installs now work.

Resolves: #59
2021-06-30 05:16:56 +01:00
BlueWolf
5c1d8b6870 fix: switched test config entry that wasnt available for deb9
The --collector.systemd config argument is unavailable in the
older packages.
The formula handles either scenario so switching the check out from the
test pillar for --log.level=debug instead

Resolved issue identified in pull request check for debian
2021-06-30 05:16:56 +01:00
BlueWolf
0ca247a37e fix: added guidance and reverted incorrected changes from prior commits
Added inspec checks for environment files and specifically prometheus
and node_exporter args. Provided comments throughout the key reference
points for users to signpost the differing approaches to args used along
with more clearly identifying the difference between archive and repo
approach. Tests appear to be working on both approaches though updates
have been focused at repo install method.

Fixes: #59
2021-06-30 05:16:56 +01:00
BlueWolf
f2261f9dc9 fix: revert to use of macro.jinja for arg handling
The previous additions to environ.sh.jinja were fixing something that wasnt broken.
2021-06-30 05:16:56 +01:00
BlueWolf
e52f804bf4 fix: rework to implement environment variables handling
Developed environ.sh.jinja and added test pillar data to default
Corrected prometheus.config.environ
Switched default test pillar to use none archive - due to deployment of custom service
Disabled a number of exporters following switch from archive due to failing - to be reviewed
Corrected prometheus environ_file location

Resolves: #59
2021-06-30 05:15:38 +01:00
BlueWolf
52845bb534 fix: removed erroneus dash (-)
Dash was incorrectly left alongside squid_exporter entry in
osfamilymap.

Resolves: #59
2021-06-29 12:40:39 +01:00
BlueWolf
4de3ebd241 fix: added handle for alternative argument opts header
Centos and oraclelinux repositories for prometheus include bespoke headers
in the environment files (e.g. Debian: ARGS=, Centos: PROMETHEUS_OPTS=
ALERTMANAGER_OPTS=). This has been added as a default pillar with osmap
variances.
Additionally archlinux repo install was failing so added basic support -
an issue still remains for the prometheus app itself due to the service
file included in the arch repo hardcoding some config options - resulting
in the possibility to duplicate arguments resulting in a service error.
The prometheus service currently does not start due to permissions not being
applied to a data folder. The added config.storage begins to solve this and
ensures alignment on all platforms but would result in a duplicate config
entry as above. Prometheus on arch therefore needs more work but the exporter
installs now work.

Resolves: #59
2021-06-27 15:04:47 +01:00
BlueWolf
4635ca7070 fix: switched test config entry that wasnt available for deb9
The --collector.systemd config argument is unavailable in the
older packages.
The formula handles either scenario so switching the check out from the
test pillar for --log.level=debug instead

Resolved issue identified in pull request check for debian
2021-06-25 13:17:41 +01:00
BlueWolf
a4dfb87554 fix: added guidance and reverted incorrected changes from prior commits
Added inspec checks for environment files and specifically prometheus
and node_exporter args. Provided comments throughout the key reference
points for users to signpost the differing approaches to args used along
with more clearly identifying the difference between archive and repo
approach. Tests appear to be working on both approaches though updates
have been focused at repo install method.

Fixes: #59
2021-06-25 10:51:30 +01:00
BlueWolf
696bee0522 fix: revert to use of macro.jinja for arg handling
The previous additions to environ.sh.jinja were fixing something that wasnt broken.
2021-06-24 17:25:35 +01:00
BlueWolf
eea5b407fa fix: rework to implement environment variables handling
Developed environ.sh.jinja and added test pillar data to default
Corrected prometheus.config.environ ref #59
Switched default test pillar to use none archive - due to deployment of custom service
Disabled a number of exporters following switch from archive due to failing - to be reviewed
Corrected prometheus environ_file location

Resolves: #59
2021-06-24 14:55:09 +01:00
Imran Iqbal
fa96aabba7
ci(kitchen+gitlab): remove Ubuntu 16.04 & Fedora 32 (EOL) [skip ci]
* Automated using https://github.com/myii/ssf-formula/pull/331
2021-06-21 20:47:50 +01:00
semantic-release-bot
ee1e08bb2c chore(release): 5.5.0 [skip ci]
# [5.5.0](https://github.com/saltstack-formulas/prometheus-formula/compare/v5.4.0...v5.5.0) (2021-05-28)

### Bug Fixes

* **clientlibs/install:** ensure `tar` is available for Oracle Linux 8 ([d30b42c](d30b42ced0))
* **node_exporter:** typo ([cc112e7](cc112e71b9)), closes [#57](https://github.com/saltstack-formulas/prometheus-formula/issues/57)
* **pillar:** fix `OverflowError: Range too big` -- `MAX_RANGE (100000)` ([c9cfdfd](c9cfdfd9e1)), closes [/gitlab.com/myii/prometheus-formula/-/jobs/1077740890#L779](https://github.com//gitlab.com/myii/prometheus-formula/-/jobs/1077740890/issues/L779)

### Continuous Integration

* add `arch-master` to matrix and update `.travis.yml` [skip ci] ([046b0ee](046b0ee239))
* **gemfile+lock:** use `ssf` customised `kitchen-docker` repo [skip ci] ([05f66ac](05f66ac9bc))
* **kitchen+ci:** use latest pre-salted images (after CVE) [skip ci] ([df0ec43](df0ec43f52))
* **kitchen+gitlab:** adjust matrix to add `3003` [skip ci] ([a9e26a7](a9e26a795d))
* **kitchen+gitlab-ci:** use latest pre-salted images [skip ci] ([e283bfb](e283bfb188))

### Documentation

* remove files which aren't formula-specific [skip ci] ([1b2c50a](1b2c50ae37))
* **readme:** fix headings and contributing link [skip ci] ([bb7b816](bb7b816aac))

### Features

* **archive:** allow command line arguments without values ([08ad2ca](08ad2caf4c))
* **config:** allow to manage extra files ([5f3dc6f](5f3dc6f11a))

### Tests

* standardise use of `share` suite & `_mapdata` state [skip ci] ([2b38c9e](2b38c9e402))
* **pillar/repo:** avoid `alertmanager` config where newer than package ([83efb0b](83efb0b434))
2021-05-28 13:59:46 +00:00
N
d304acef89
Merge pull request #56 from netmanagers/master
feat(config): allow to manage extra files
2021-05-28 14:48:52 +01:00
N
6ff86756ab
Merge pull request #58 from netmanagers/fix-typo
fix(node_exporter): typo
2021-05-28 14:46:46 +01:00
Javier Bértoli
cc112e71b9 fix(node_exporter): typo
closes #57
2021-05-28 09:43:49 -03:00
Javier Bértoli
5f3dc6f11a feat(config): allow to manage extra files 2021-05-27 20:42:32 -03:00
Imran Iqbal
babe311306
chore(pre-commit): use info report level for rstcheck [skip ci]
* Automated using https://github.com/myii/ssf-formula/pull/325
2021-05-20 14:10:06 +01:00
Imran Iqbal
1b2c50ae37
docs: remove files which aren't formula-specific [skip ci]
Further reason is to avoid issues with `rst-lint`:

```
ERROR docs/index.rst:10 Unknown directive type "toctree".
```
2021-05-17 18:59:42 +01:00
N
7c69be2077
Merge pull request #55 from corey-hammerton/systemd-params-null
feat(archive): allow command line arguments without values in archive.install
2021-05-15 12:55:52 +01:00
Imran Iqbal
046b0ee239
ci: add arch-master to matrix and update .travis.yml [skip ci]
* Automated using https://github.com/myii/ssf-formula/pull/323
2021-05-09 22:33:17 +01:00
Imran Iqbal
bb7b816aac
docs(readme): fix headings and contributing link [skip ci] 2021-05-05 15:21:42 +01:00
chammerton
08ad2caf4c feat(archive): allow command line arguments without values
* If a service.args value is define as null, only render the param (key) in the systemd unit file
2021-05-03 11:17:32 -04:00
Imran Iqbal
a9e26a795d
ci(kitchen+gitlab): adjust matrix to add 3003 [skip ci]
* Automated using https://github.com/myii/ssf-formula/pull/318
2021-04-23 08:49:01 +01:00
Imran Iqbal
ed1ee70605
chore: update CODEOWNERS & .yamllint re: kitchen-vagrant [skip ci]
* Automated using https://github.com/myii/ssf-formula/pull/310
2021-04-05 18:21:18 +01:00
Imran Iqbal
2b38c9e402
test: standardise use of share suite & _mapdata state [skip ci]
* Automated using https://github.com/myii/ssf-formula/pull/302
2021-03-23 21:32:19 +00:00
Imran Iqbal
df0ec43f52
ci(kitchen+ci): use latest pre-salted images (after CVE) [skip ci]
* Automated using https://github.com/myii/ssf-formula/pull/299
2021-03-07 22:04:44 +00:00
Imran Iqbal
c9cfdfd9e1
fix(pillar): fix OverflowError: Range too big -- MAX_RANGE (100000)
https://gitlab.com/myii/prometheus-formula/-/jobs/1077740890#L779

```
Traceback (most recent call last):
  File "/usr/local/lib/python3.8/dist-packages/salt/utils/templates.py", line 501, in render_jinja_tmpl
    output = template.render(**decoded_context)
  File "/usr/local/lib/python3.8/dist-packages/jinja2/environment.py", line 1090, in render
    self.environment.handle_exception()
  File "/usr/local/lib/python3.8/dist-packages/jinja2/environment.py", line 832, in handle_exception
    reraise(*rewrite_traceback_stack(source=source))
  File "/usr/local/lib/python3.8/dist-packages/jinja2/_compat.py", line 28, in reraise
    raise value.with_traceback(tb)
  File "<template>", line 212, in top-level template code
  File "/usr/local/lib/python3.8/dist-packages/jinja2/sandbox.py", line 462, in call
    return __context.call(__obj, *args, **kwargs)
  File "/usr/local/lib/python3.8/dist-packages/jinja2/sandbox.py", line 173, in safe_range
    raise OverflowError(
OverflowError: Range too big. The sandbox blocks ranges larger than MAX_RANGE (100000).

; line 212

---
[...]
   skip_verify: true

  linux:
    # 'Alternatives system' priority: zero disables (default)
    # yamllint disable-line rule:braces
    altpriority: {{ range(1, 9100000) | random }}    <======================
```
2021-03-07 22:04:39 +00:00
Imran Iqbal
a7875aea8a
chore(yamllint): add .git/ to ignores [skip ci]
* Automated using https://github.com/myii/ssf-formula/pull/297
2021-03-05 18:34:45 +00:00