Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 12 additions & 12 deletions .fixtures.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,48 +2,48 @@ fixtures:
repositories:
apt:
repo: https://github.com/puppetlabs/puppetlabs-apt.git
ref: 5.0.1
ref: v9.1.0
stdlib:
repo: https://github.com/puppetlabs/puppetlabs-stdlib.git
ref: 5.1.0
ref: v9.3.0
datacat:
repo: https://github.com/richardc/puppet-datacat.git
ref: 0.6.2
yumrepo_core:
repo: https://github.com/puppetlabs/puppetlabs-yumrepo_core
ref: 1.0.1
ref: v2.0.0
puppet_version: ">= 6.0.0"
chocolatey:
repo: https://github.com/puppetlabs/puppetlabs-chocolatey.git
ref: 3.0.0
ref: v8.0.0
# Needed by chocolatey
registry:
repo: https://github.com/puppetlabs/puppetlabs-registry.git
ref: 1.0.0
ref: v5.0.1
# Needed by chocolatey
powershell:
repo: https://github.com/puppetlabs/puppetlabs-powershell.git
ref: 1.0.1
ref: v6.0.0
# Need by postgresql
augeas_core:
repo: https://github.com/puppetlabs/puppetlabs-augeas_core
ref: 1.0.4
ref: v1.4.0
puppet_version: ">= 6.0.0"
# Need by postgresql
concat:
repo: https://github.com/puppetlabs/puppetlabs-concat.git
ref: v6.0.0
ref: v9.0.0
postgresql:
repo: https://github.com/puppetlabs/puppetlabs-postgresql.git
ref: v6.4.0
ref: v9.1.0
archive:
repo: https://github.com/voxpupuli/puppet-archive.git
ref: 'v3.0.0'
ref: v7.0.0
windows_env:
repo: https://github.com/voxpupuli/puppet-windows_env.git
ref: 'v3.0.0'
ref: v5.0.0
systemd:
repo: https://github.com/camptocamp/puppet-systemd.git
ref: '2.0.0'
ref: v8.3.0
symlinks:
sensu: "#{source_dir}"
15 changes: 9 additions & 6 deletions .github/workflows/acceptance-cluster.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,24 +15,26 @@ jobs:
fail-fast: false
matrix:
puppet:
- puppet6
- puppet7
- puppet8
use_agent:
- no
- yes
ci_build:
- no
set:
- rocky-8-cluster
- ubuntu-24.04-cluster
env:
BEAKER_debug: true
name: Sensu Go Cluster ${{ matrix.puppet }} (use-agent=${{ matrix.use_agent }} CI=${{ matrix.ci_build }})
name: Sensu Go Cluster ${{ matrix.set }} ${{ matrix.puppet }} (use-agent=${{ matrix.use_agent }} CI=${{ matrix.ci_build }})
steps:
- uses: actions/checkout@v2
- name: Setup ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: '2.7'
ruby-version: ${{ matrix.puppet == 'puppet8' && '3.2.5' || '3.1.4' }}
bundler-cache: true
bundler: '2.1.0'
bundler: '2.4.10'
- name: Decrypt secrets
env:
SENSU_SECRETS_PASSWORD: ${{ secrets.SENSU_SECRETS_PASSWORD }}
Expand All @@ -41,8 +43,9 @@ jobs:
- name: Run tests
run: bundle exec rake acceptance
env:
RUN_ACCEPTANCE: 1
BEAKER_PUPPET_COLLECTION: ${{ matrix.puppet }}
BEAKER_set: centos-7-cluster
BEAKER_set: ${{ matrix.set }}
BEAKER_sensu_mode: cluster
BEAKER_sensu_use_agent: ${{ matrix.use_agent }}
BEAKER_sensu_ci_build: ${{ matrix.ci_build }}
23 changes: 12 additions & 11 deletions .github/workflows/acceptance-full.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,23 +20,23 @@ jobs:
- types
- examples
puppet:
- puppet6
- puppet7
- puppet8
use_agent:
- no
ci_build:
- no
set:
- rocky-9-modern
- ubuntu-24.04-modern
include:
- sensu_mode: types
puppet: puppet6
use_agent: yes
ci_build: no
- sensu_mode: types
puppet: puppet7
puppet: puppet8
use_agent: yes
ci_build: no
set: rocky-9-modern
- sensu_mode: bolt
puppet: puppet6
puppet: puppet8
set: rocky-9-modern
env:
BEAKER_debug: true
name: ${{ matrix.set }} ${{ matrix.puppet }} (mode=${{ matrix.sensu_mode }} use-agent=${{ matrix.use_agent }} CI=${{ matrix.ci_build }})
Expand All @@ -45,9 +45,9 @@ jobs:
- name: Setup ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: '2.7'
ruby-version: ${{ matrix.puppet == 'puppet8' && '3.2.5' || '3.1.4' }}
bundler-cache: true
bundler: '2.1.0'
bundler: '2.4.10'
- name: Decrypt secrets
env:
SENSU_SECRETS_PASSWORD: ${{ secrets.SENSU_SECRETS_PASSWORD }}
Expand All @@ -56,8 +56,9 @@ jobs:
- name: Run tests
run: bundle exec rake acceptance
env:
RUN_ACCEPTANCE: 1
BEAKER_PUPPET_COLLECTION: ${{ matrix.puppet }}
BEAKER_set: centos-7
BEAKER_set: ${{ matrix.set }}
BEAKER_sensu_mode: ${{ matrix.sensu_mode }}
BEAKER_sensu_use_agent: ${{ matrix.use_agent }}
BEAKER_sensu_ci_build: ${{ matrix.ci_build }}
22 changes: 13 additions & 9 deletions .github/workflows/acceptance.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,20 +15,21 @@ jobs:
fail-fast: false
matrix:
set:
- centos-7
- rocky-8
- debian-10
- ubuntu-1804
- ubuntu-2004
- amazonlinux-201803
- rocky-9-modern
- debian-12-modern
- ubuntu-24.04-modern
- ubuntu-22.04-modern
- almalinux-9-modern
puppet:
- puppet6
- puppet7
- puppet8
ci_build:
- no
exclude:
- puppet: puppet7
ci_build: yes
- puppet: puppet8
ci_build: yes
env:
BEAKER_debug: true
name: ${{ matrix.set }} ${{ matrix.puppet }} (ci=${{ matrix.ci_build }})
Expand All @@ -37,9 +38,9 @@ jobs:
- name: Setup ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: '2.7'
ruby-version: ${{ matrix.puppet == 'puppet8' && '3.2.5' || '3.1.4' }}
bundler-cache: true
bundler: '2.1.0'
bundler: '2.4.10'
- name: Decrypt secrets
env:
SENSU_SECRETS_PASSWORD: ${{ secrets.SENSU_SECRETS_PASSWORD }}
Expand All @@ -48,6 +49,9 @@ jobs:
- name: Run tests
run: bundle exec rake acceptance
env:
RUN_ACCEPTANCE: 1
BEAKER_PUPPET_COLLECTION: ${{ matrix.puppet }}
BEAKER_set: ${{ matrix.set }}
BEAKER_sensu_mode: base
BEAKER_sensu_use_agent: no
BEAKER_sensu_ci_build: ${{ matrix.ci_build }}
4 changes: 2 additions & 2 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ jobs:
- name: Setup Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: '2.7'
ruby-version: '3.1.4'
bundler-cache: true
bundler: '2.1.0'
bundler: '2.4.10'
- name: Build and Deploy
env:
BLACKSMITH_FORGE_USERNAME: sensu
Expand Down
22 changes: 7 additions & 15 deletions .github/workflows/unit.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,22 +16,14 @@ jobs:
fail-fast: false
matrix:
include:
- ruby: 2.5.7
puppet: 6
- ruby: 3.1.4
puppet: 7
fixtures: .fixtures.yml
allow_failure: false
- ruby: 2.7.6
puppet: 7
- ruby: 3.2.5
puppet: 8
fixtures: .fixtures.yml
allow_failure: false
- ruby: 2.5.7
puppet: 6
fixtures: .fixtures-latest.yml
allow_failure: true
- ruby: 2.7.6
puppet: 7
fixtures: .fixtures-latest.yml
allow_failure: true
env:
BUNDLE_WITHOUT: system_tests:development
PUPPET_GEM_VERSION: "~> ${{ matrix.puppet }}.0"
Expand All @@ -44,8 +36,8 @@ jobs:
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true
bundler: '2.1.0'
bundler: '2.4.10'
- name: Validate
run: bundle exec rake sensu_validate lint strings:generate reference
run: bundle exec rake sensu_validate lint reference
- name: Run tests
run: bundle exec rake parallel_spec
run: bundle exec rake spec
1 change: 0 additions & 1 deletion .pdkignore
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@
.project
.envrc
/inventory.yaml
/appveyor.yml
/.fixtures.yml
/Gemfile
/.gitattributes
Expand Down
2 changes: 0 additions & 2 deletions .sync.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,5 @@ spec/spec_helper.rb:
paths: *ignorepaths
Gemfile:
unmanaged: true
appveyor.yml:
unmanaged: true
.rspec:
unmanaged: true
15 changes: 6 additions & 9 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,12 @@ end

group :development, :unit_tests do
gem 'rake'
gem 'net-ftp', require: false
gem 'rspec-puppet', :require => false
gem 'rspec-puppet-facts', :require => false
gem 'rspec-mocks', :require => false
gem 'parallel_tests', :require => false
gem 'puppetlabs_spec_helper', :require => false
gem 'puppetlabs_spec_helper', '~> 5.0', :require => false
gem 'metadata-json-lint', :require => false
gem 'puppet-blacksmith', :require => false
gem 'puppet-lint', :require => false
Expand All @@ -34,20 +35,16 @@ group :development, :unit_tests do
gem 'puppet-lint-param-docs', :require => false
gem 'puppet-lint-resource_reference_syntax', :require => false
gem 'puppet-lint-spaceship_operator_without_tag-check', :require => false
gem 'puppet-lint-top_scope_facts-check', :require => false
# Removed: puppet-lint-top_scope_facts-check (incompatible with newer puppetlabs_spec_helper)
gem 'puppet-lint-topscope-variable-check', :require => false
gem 'puppet-lint-trailing_comma-check', :require => false
gem 'puppet-lint-trailing_newline-check', :require => false
gem 'puppet-lint-undef_in_function-check', :require => false
# Removed: puppet-lint-undef_in_function-check (incompatible with newer puppet-lint)
gem 'puppet-lint-unquoted_string-check', :require => false
gem 'puppet-lint-variable_contains_upcase', :require => false
gem 'puppet-lint-version_comparison-check', :require => false
gem 'rubocop', '~> 0.49.0', :require => false
gem 'rubocop-i18n', '~> 1.2.0', :require => false
gem 'rubocop-rspec', '~> 1.16.0', :require => false
if Gem.win_platform? && ENV['PUPPET_GEM_VERSION'] =~ /6.x/
gem 'ffi', '~>1.11.0', :require => false
end
gem 'rubocop', '~> 1.50.0', :require => false
gem 'rubocop-rspec', '~> 2.20.0', :require => false
end

group :documentation do
Expand Down
20 changes: 17 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -176,14 +176,28 @@ This module will install packages, create configuration and start services neces

### Setup requirements

#### Puppet and Ruby Version Requirements

This module requires specific Ruby versions depending on the Puppet version:

| Puppet Version | Required Ruby Version | Support Status |
|----------------|----------------------|----------------|
| Puppet 7.x | Ruby 3.1.x | ✅ Supported |
| Puppet 8.x | Ruby 3.2.x | ✅ Supported |
| Puppet 6.x | Ruby 2.5.x - 2.7.x | ❌ EOL (Removed) |

**Important**: Ensure your environment has the correct Ruby version for your Puppet version. Using incompatible versions may cause unexpected failures.

#### Plugin Sync

Plugin sync is required if the custom sensu types and providers are used.

#### Soft module dependencies

For systems using `apt`:
* [puppetlabs/apt](https://forge.puppet.com/puppetlabs/apt) module (`>= 5.0.1 < 9.0.0`)

For systems using `yum` and Puppet >= 6.0.0:
For systems using `yum` and Puppet >= 7.0.0:
* [puppetlabs/yumrepo_core](https://forge.puppet.com/puppetlabs/yumrepo_core) module (`>= 1.0.1 < 2.0.0`)

For Windows:
Expand Down Expand Up @@ -1266,8 +1280,8 @@ When changing the `sensu::password` value, it's necessary to run Puppet on the b

### Notes regarding support

This module is built for use with Puppet versions 6 and 7 and the ruby
versions associated with those releases. See `.travis.yml` for an exact
This module is built for use with Puppet versions 7 and 8 and the ruby
versions associated with those releases. See `.github/workflows/` for an exact
matrix of Puppet releases and ruby versions.

This module targets the latest release of the current major Puppet
Expand Down
10 changes: 8 additions & 2 deletions REFERENCE.md
Original file line number Diff line number Diff line change
Expand Up @@ -4799,7 +4799,7 @@ Default value: `/etc/sensu/ssl/ca.crt`

URL to use with 'sensuctl configure'

Default value: `http://127.0.0.1:8080`
Default value: `https://127.0.0.1:8080`

##### <a name="-sensu_user--name"></a>`name`

Expand Down Expand Up @@ -4926,7 +4926,7 @@ Sensu Backend URL's require protocol of ws:// or wss://.
A port is also required.
There is logic in sensu::agent class to add the protocol so it's optional.

Alias of `Variant[Pattern[/^[^\s:]+:\d+$/], Pattern[/^ws:\/\/[^\s:]+:\d+$/], Pattern[/^wss:\/\/[^\s:]++:\d+$/]]`
Alias of `Variant[Pattern[/^[^\s:]+:\d+$/], Pattern[/^ws:\/\/[^\s:]+:\d+$/], Pattern[/^wss:\/\/[^\s:]+:\d+$/]]`

## Tasks

Expand Down Expand Up @@ -5172,6 +5172,12 @@ Data type: `Optional[String[1]]`

The namespace for the agent, default is 'default'

##### `use_ssl`

Data type: `Optional[Boolean]`

Whether to use SSL for backend API connections, default is true

##### `output`

Data type: `Optional[Boolean]`
Expand Down
1 change: 1 addition & 0 deletions Rakefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
require 'json'
require 'bundler'
require 'puppetlabs_spec_helper/rake_tasks'
require 'puppet-lint/tasks/puppet-lint'
require 'puppet_blacksmith/rake_tasks' if Bundler.rubygems.find_name('puppet-blacksmith').any?
Expand Down
Loading
Loading