Skip to content

Commit

Permalink
Merge branch 'main' into feature/icingaweb-module-graphite
Browse files Browse the repository at this point in the history
  • Loading branch information
mkayontour committed Nov 13, 2024
2 parents 4f8c8c1 + 4ee41f7 commit dc0d956
Show file tree
Hide file tree
Showing 102 changed files with 1,150 additions and 231 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ jobs:
max-parallel: 1
matrix:
distro: [ubuntu2204]
python: ['3.9', '3.10']
ansible: ['2.13.10', '2.14.7']
python: ['3.10', '3.11']
ansible: ['2.15', '2.16', '2.17']
scenario: [default]

steps:
Expand Down
66 changes: 66 additions & 0 deletions .github/workflows/role-icingadb.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
---
# These Jobs should be always be run against the latest version of ansible on the systems
# Feel free to update python and ansible versions
#
# In addition to keep them quick and no additional variables are used.
#
name: role-icingadb
on:
push:
branches:
- main
- 'feature/**'
- 'fix/**'
- '!doc/**'
paths:
- roles/icingadb/**
- molecule/role-icingadb/**
pull_request:
branches:
- 'feature/**'
- 'fix/**'
- '!doc/**'

jobs:
icingadb_latest:
runs-on: ubuntu-latest

env:
COLLECTION_NAMESPACE: icinga
COLLECTION_NAME: icinga

strategy:
fail-fast: false
max-parallel: 1
matrix:
distro: [ubuntu2204]
python: ['3.12']
ansible: ['2.17']
scenario: [role-icingadb]

steps:
- name: Check out code
uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}

- name: Install dependencies ansible
run: |
python3 -m pip install --upgrade pip
python3 -m pip install -r requirements-test-${{ matrix.ansible }}.txt
- name: Install collection
run: |
mkdir -p ~/.ansible/collections/ansible_collections/$COLLECTION_NAMESPACE
cp -a ../ansible-collection-$COLLECTION_NAME ~/.ansible/collections/ansible_collections/$COLLECTION_NAMESPACE/$COLLECTION_NAME
- name: Test with molecule
run: |
ansible --version
molecule --version
molecule test -s ${{ matrix.scenario }}
env:
MOLECULE_DISTRO: ${{ matrix.distro }}
6 changes: 3 additions & 3 deletions .github/workflows/role-icingadb_redis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,16 +34,16 @@ jobs:
max-parallel: 1
matrix:
distro: [ubuntu2204]
python: ['3.10']
ansible: ['2.16.2']
python: ['3.12']
ansible: ['2.17']
scenario: [role-icingadb_redis]

steps:
- name: Check out code
uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}

Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/role-icingaweb2.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,16 +34,16 @@ jobs:
max-parallel: 1
matrix:
distro: [ubuntu2204]
python: ['3.10']
ansible: ['2.16.2']
python: ['3.12']
ansible: ['2.17']
scenario: [role-icingaweb2]

steps:
- name: Check out code
uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}

Expand Down
94 changes: 91 additions & 3 deletions .github/workflows/test_icingaweb2_ini_template.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,16 @@ on:
paths:
- 'roles/icingaweb2/templates/**'
- 'molecule/ini-configuration-tests/**'
- '.github/workflows/test_icingaweb2_ini_template.yml'
- 'requirements*'
pull_request:
branches:
- 'feature/**'
- 'fix/**'
- '!doc/**'

jobs:
test_ini_template:
test_ini_template_2_15:
runs-on: ubuntu-latest

env:
Expand All @@ -30,8 +32,94 @@ jobs:
max-parallel: 1
matrix:
distro: [ubuntu2204]
python: ['3.9', '3.10']
ansible: ['2.13.10', '2.14.7']
python: ['3.9','3.10','3.11']
ansible: ['2.15']
scenario: [ini-configuration-tests]

steps:
- name: Check out code
uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}

- name: Install dependencies ansible
run: |
python3 -m pip install --upgrade pip
python3 -m pip install -r requirements-test-${{ matrix.ansible }}.txt
- name: Install collection
run: |
mkdir -p ~/.ansible/collections/ansible_collections/$COLLECTION_NAMESPACE
cp -a ../ansible-collection-$COLLECTION_NAME ~/.ansible/collections/ansible_collections/$COLLECTION_NAMESPACE/$COLLECTION_NAME
- name: Test with molecule
run: |
ansible --version
molecule --version
molecule test -s ${{ matrix.scenario }}
env:
MOLECULE_DISTRO: ${{ matrix.distro }}

test_ini_template_2_16:
runs-on: ubuntu-latest

env:
COLLECTION_NAMESPACE: icinga
COLLECTION_NAME: icinga

strategy:
fail-fast: false
max-parallel: 1
matrix:
distro: [ubuntu2204]
python: ['3.10','3.11','3.12']
ansible: ['2.16']
scenario: [ini-configuration-tests]

steps:
- name: Check out code
uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}

- name: Install dependencies ansible
run: |
python3 -m pip install --upgrade pip
python3 -m pip install -r requirements-test-${{ matrix.ansible }}.txt
- name: Install collection
run: |
mkdir -p ~/.ansible/collections/ansible_collections/$COLLECTION_NAMESPACE
cp -a ../ansible-collection-$COLLECTION_NAME ~/.ansible/collections/ansible_collections/$COLLECTION_NAMESPACE/$COLLECTION_NAME
- name: Test with molecule
run: |
ansible --version
molecule --version
molecule test -s ${{ matrix.scenario }}
env:
MOLECULE_DISTRO: ${{ matrix.distro }}

test_ini_template_2_17:
runs-on: ubuntu-latest

env:
COLLECTION_NAMESPACE: icinga
COLLECTION_NAME: icinga

strategy:
fail-fast: false
max-parallel: 1
matrix:
distro: [ubuntu2204]
python: ['3.10','3.11','3.12']
ansible: ['2.17']
scenario: [ini-configuration-tests]

steps:
Expand Down
31 changes: 31 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,37 @@ Icinga.Icinga Release Notes

.. contents:: Topics

v0.3.4
======

Release Summary
---------------

Bugfix release

Bugfixes
--------

- Added missing port paramater to mysql command within icingadb role (#267)
- Fixed collect of icinga2_objects when icinga2_config_host is not defined (#228)
- Fixed issue where reusing the repos role within the monitoring_plugins could cause the deactivation of the repos; using standalone task now (#270)
- Icinga's packages no longer create '/var/log/icingadb-redis/'. Added tasks that create a log directory based on `icingadb_redis_logfile` (#298).

v0.3.3
======

Release Summary
---------------

Bugfix Release

Bugfixes
--------

- ensure backwards compatibility with bool filter (#218)
- icinga2 feature api: fixed missing quotes in delegate ticket command for satellites or second master nodes.(#250)
- icingaweb2: run pqslcmd with LANG=C to ensure the output is in english.(#241)
- remove superfluous curly brace (#246)

v0.3.2
======
Expand Down
67 changes: 67 additions & 0 deletions PUBLISH.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
# Creating a new release

> This is meant as an *internal* note on how to build and publish a new version of this Ansible Collection.
1. **Get the release branch ready:**
Push your local changes to the remote.
From your local release branch:
```
git push --set-upstream origin release/<VERSION>
```

To avoid having leftover files from your local directory end up in the release, please **cleanly clone the release branch to another directory**.
```
git clone --branch release/<VERSION> git@github.com:Icinga/ansible-collection-icinga.git release_<VERSION>
cd release_<VERSION>
```
You now only have files that were actually commmited.

2. **Increase the version number:**
The version of this Collection - as seen by Ansible Galaxy - is determined by **galaxy.yml**.
Increase the version number inside accordingly.

3. **Create a changelog summary:**
This will be shown in the changelog as a short summary for this release.

changelogs/fragments/release_summary.yml:
```
release_summary: |
Summary text for this release.
"*Bugfix release*" for example.
```

4. **Create a new changelog:**
Lint the changelogs:
```
antsibull-changelog lint
```

Generate the changelog:
```
antsibull-changelog release --version <VERSION>
```

Commit your changes to the release branch.

5. **Build and push to Ansible Galaxy:**
Build a release tar ball (verbose shows skipped files):
```
ansible-galaxy collection build -vvv
```

Push to Ansible Galaxy:
```
ansible-galaxy collection publish --token <TOKEN> icinga-icinga-<VERSION>.tar.gz
```
> This might show errors which does **not** necessarily mean that it failed.
> Have a look at [Ansible Galaxy](https://galaxy.ansible.com/ui/repo/published/icinga/icinga/) and confirm if the release could be published.
6. **Create a release on GitHub:**
When [creating a new release](https://github.com/Icinga/ansible-collection-icinga/releases/new)

- choose \<VERSION\> as tag
- choose the branch "release/\<VERSION\>" as target (will be tagged)
- choose \<VERSION\> as title
- copy and paste the release's changelog entry (see [prior releases](https://github.com/Icinga/ansible-collection-icinga/releases))
- attach the created tar ball (icinga-icinga-\<VERSION\>.tar.gz) to the release
- if you feel extra nice, credit contributors by adding their names, e.g. behind the respective issue or feature (`@name`)
31 changes: 31 additions & 0 deletions changelogs/changelog.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -124,3 +124,34 @@ releases:
- feature_adjust_director_source_installation.yml
- release.yml
release_date: '2023-12-07'
0.3.3:
changes:
bugfixes:
- ensure backwards compatibility with bool filter (#218)
- 'icinga2 feature api: fixed missing quotes in delegate ticket command for
satellites or second master nodes.(#250)'
- 'icingaweb2: run pqslcmd with LANG=C to ensure the output is in english.(#241)'
- remove superfluous curly brace (#246)
release_summary: Bugfix Release
fragments:
- fix_missing_quotes_delegate_ticket.yml
release_date: '2024-01-15'
0.3.4:
changes:
bugfixes:
- Added missing port paramater to mysql command within icingadb role (#267)
- Fixed collect of icinga2_objects when icinga2_config_host is not defined (#228)
- Fixed issue where reusing the repos role within the monitoring_plugins could
cause the deactivation of the repos; using standalone task now (#270)
- Icinga's packages no longer create '/var/log/icingadb-redis/'. Added tasks
that create a log directory based on `icingadb_redis_logfile` (#298).
release_summary: Bugfix release
fragments:
- fix_issue_228.yml
- fix_issue_267.yml
- fix_issue_268.yml
- fix_issue_269.yml
- fix_issue_270.yml
- fix_issue_298.yml
- release_summary.yml
release_date: '2024-07-25'
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
---
minor_changes:
- Added support for PostgresQL databases for Icingaweb2 modules that support it
3 changes: 3 additions & 0 deletions changelogs/fragments/feature_monitoring_plugins_suse.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
---
minor_changes:
- Add support for Suse in the :code:`monitoring_plugins` role.
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
---

minor_changes:
- Change documentation to better reflect the intended usage of the variable 'icinga2_objects' as a host variable vs. as a play variable.
3 changes: 3 additions & 0 deletions changelogs/fragments/fix_327_unavailable_plugin.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
---
bugfixes:
- Fixed a bug in :code:`monitoring_plugins` where a requested plugin that is **unavailable** would cause a failure even though it is a **known** plugin and should be skipped (#327).
3 changes: 3 additions & 0 deletions changelogs/fragments/fix_issue_298.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
---
bugfixes:
- Icinga's packages no longer create '/var/log/icingadb-redis/'. Added tasks that create a log directory based on `icingadb_redis_logfile` (#298).
2 changes: 2 additions & 0 deletions changelogs/fragments/fix_issue_301.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
bugfixes:
- "Certain values within Icinga Web :code:`ini` files got quoted incorrectly using single quotes. They are now quoted properly using double quotes (#301)."
Loading

0 comments on commit dc0d956

Please sign in to comment.