Skip to content

Commit

Permalink
(SIMP-7322) Add EL8 support (#54)
Browse files Browse the repository at this point in the history
* (SIMP-7322) Add EL8 support

SIMP-7322 #close
SIMP-7202 #comment Add EL8 support to simp-postfix

* Update CHANGELOG entry.  Update puppet version in gitlab-ci to 5.5.16

Co-authored-by: jeannegreulich <jeanne.greulich@onyxpoint.com>
  • Loading branch information
trevor-vaughan and jeannegreulich committed Dec 31, 2019
1 parent 01db137 commit b8905db
Show file tree
Hide file tree
Showing 12 changed files with 102 additions and 51 deletions.
14 changes: 8 additions & 6 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,18 @@
.yardoc
dist/
pkg/
spec/fixtures/*
!spec/fixtures/hieradata/
!spec/fixtures/hieradata/*
spec/fixtures/hieradata/hiera.yaml
spec/rp_env/
spec/fixtures/**
!spec/fixtures/site.pp
!spec/fixtures/inspec_profiles
.bundle/
.rspec_system
.vagrant/
.bundle/
Gemfile.lock
doc/
vendor/
junit/
log/
sec_results/
vendor/
doc/
.idea/
28 changes: 14 additions & 14 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
# https://puppet.com/docs/pe/2018.1/overview/getting_support_for_pe.html
# ------------------------------------------------------------------------------
# Release Puppet Ruby EOL
# SIMP 6.3 5.5.10 2.4.5 TBD***
# PE 2018.1 5.5.8 2.4.5 2020-05 (LTS)***
# SIMP 6.3 5.5.16 2.4.5 TBD***
# PE 2018.1 5.5.16 2.4.5 2020-05 (LTS)***
# PE 2019.0 6.0 2.5.1 2019-08-31^^^
#
# *** = Modules created for SIMP 6.3+ are not required to support Puppet < 5.5
Expand Down Expand Up @@ -69,10 +69,10 @@ variables:
BEAKER_PUPPET_COLLECTION: 'puppet5'
MATRIX_RUBY_VERSION: '2.4'

.pup_5_5_10: &pup_5_5_10
.pup_5_5_16: &pup_5_5_16
image: 'ruby:2.4'
variables:
PUPPET_VERSION: '5.5.10'
PUPPET_VERSION: '5.5.16'
BEAKER_PUPPET_COLLECTION: 'puppet5'
MATRIX_RUBY_VERSION: '2.4'

Expand Down Expand Up @@ -149,8 +149,8 @@ pup5-unit:
<<: *pup_5
<<: *unit_tests

pup5.5.10-unit:
<<: *pup_5_5_10
pup5.5.16-unit:
<<: *pup_5_5_16
<<: *unit_tests

pup6-unit:
Expand All @@ -159,26 +159,26 @@ pup6-unit:

# Acceptance tests
# ==============================================================================
pup5.5.10:
<<: *pup_5_5_10
pup5.5.16:
<<: *pup_5_5_16
<<: *acceptance_base
script:
- 'bundle exec rake beaker:suites'

pup5.5.10-fips:
<<: *pup_5_5_10
pup5.5.16-fips:
<<: *pup_5_5_16
<<: *acceptance_base
script:
- 'BEAKER_fips=yes bundle exec rake beaker:suites'

pup5.5.10-oel:
<<: *pup_5_5_10
pup5.5.16-oel:
<<: *pup_5_5_16
<<: *acceptance_base
script:
- 'bundle exec rake beaker:suites[default,oel]'

pup5.5.10-oel-fips:
<<: *pup_5_5_10
pup5.5.16-oel-fips:
<<: *pup_5_5_16
<<: *acceptance_base
<<: *only_with_SIMP_FULL_MATRIX
script:
Expand Down
3 changes: 3 additions & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
* Tue Dec 24 2019 Trevor Vaughan <tvaughan@onyxpoint.com> - 5.5.0-0
- Add EL8 support

* Wed Sep 11 2019 Trevor Vaughan <tvaughan@onyxpoint.com> - 5.4.0-0
- Add support for simp-simplib 4

Expand Down
7 changes: 3 additions & 4 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,18 +13,17 @@ group :test do
gem 'puppet-strings'
gem 'puppet-lint-empty_string-check', :require => false
gem 'puppet-lint-trailing_comma-check', :require => false
gem 'simp-rspec-puppet-facts', ENV.fetch('SIMP_RSPEC_PUPPET_FACTS_VERSION', '~> 2.2')
gem 'simp-rake-helpers', ENV.fetch('SIMP_RAKE_HELPERS_VERSION', '~> 5.6')
gem 'simp-rspec-puppet-facts', ENV.fetch('SIMP_RSPEC_PUPPET_FACTS_VERSION', ['>= 2.4.0', '< 3.0.0'] )
gem 'simp-rake-helpers', ENV.fetch('SIMP_RAKE_HELPERS_VERSION', ['>= 5.9', '< 6.0'])
end

group :development do
gem 'pry'
gem 'pry-byebug'
gem 'pry-doc'
end

group :system_tests do
gem 'beaker'
gem 'beaker-rspec'
gem 'simp-beaker-helpers', ENV.fetch('SIMP_BEAKER_HELPERS_VERSION', '~> 1.12')
gem 'simp-beaker-helpers', ENV.fetch('SIMP_BEAKER_HELPERS_VERSION', ['>= 1.17.0', '< 2.0.0'])
end
15 changes: 12 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,17 @@ If you find any issues, they can be submitted to our [JIRA](https://simp-project

Please read our [Contribution Guide](https://simp.readthedocs.io/en/stable/contributors_guide/index.html).

## Work in Progress
## Module Description

Please excuse us as we transition this code into the public domain.
This module provides for the configuration of the [postfix](http://www.postfix.org/) mail server.

Downloads, discussion, and patches are still welcome!
## Reference

Plesae see [REFERENCE.md](./REFERENCE.md) for a full reference.

# Development

Please read our [Contribution Guide](https://simp.readthedocs.io/en/stable/contributors_guide/index.html).

Visit the [project homepage](https://simp-project.com) and look at our issues on
[JIRA](https://simp-project.atlassian.net).
19 changes: 19 additions & 0 deletions REFERENCE.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,11 @@

* [`postfix_main_cf`](#postfix_main_cf): Modifies settings in the postfix main.cf configuration file.

**Data types**

* [`Postfix::InetProtocols`](#postfixinetprotocols): Allowed inet protocol settings
* [`Postfix::ManCiphers`](#postfixmanciphers): Allowed mandatory ciphers

## Classes

### postfix
Expand Down Expand Up @@ -315,3 +320,17 @@ namevar

The parameter to modify.

## Data types

### Postfix::InetProtocols

Allowed inet protocol settings

Alias of `Array[Enum['all','ipv4','ipv6']]`

### Postfix::ManCiphers

Allowed mandatory ciphers

Alias of `Enum['export', 'low', 'medium', 'high', 'null']`

3 changes: 3 additions & 0 deletions lib/puppet/provider/postfix_main_cf/ruby.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
Puppet::Type.type(:postfix_main_cf).provide(:ruby) do
desc <<-EOM
Provides for setting items in the postfix main.cf configuration file.
EOM

commands :postconf => 'postconf'

Expand Down
8 changes: 7 additions & 1 deletion manifests/server.pp
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,8 @@
}

if $firewall {
simplib::assert_optional_dependency($module_name, 'simp/iptables')

include 'iptables'

$_dports = $enable_user_connect ? {
Expand All @@ -108,7 +110,11 @@
}

if $enable_tls {
if $haveged { include 'haveged' }
if $haveged {
simplib::assert_optional_dependency($module_name, 'simp/haveged')

include 'haveged'
}

if $enforce_tls {
postfix_main_cf { 'smtp_enforce_tls': value => 'yes' }
Expand Down
31 changes: 19 additions & 12 deletions metadata.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "simp-postfix",
"version": "5.4.0",
"version": "5.5.0",
"author": "SIMP Team",
"summary": "Manages the Postfix mail server",
"license": "Apache-2.0",
Expand All @@ -15,14 +15,6 @@
"mail"
],
"dependencies": [
{
"name": "simp/haveged",
"version_requirement": ">= 0.3.2 < 1.0.0"
},
{
"name": "simp/iptables",
"version_requirement": ">= 6.0.0 < 7.0.0"
},
{
"name": "puppetlabs/concat",
"version_requirement": ">= 3.0.0 < 7.0.0"
Expand All @@ -36,26 +28,41 @@
"version_requirement": ">= 4.13.1 < 7.0.0"
}
],
"simp": {
"optional_dependencies": [
{
"name": "simp/haveged",
"version_requirement": ">= 0.3.2 < 1.0.0"
},
{
"name": "simp/iptables",
"version_requirement": ">= 6.0.0 < 7.0.0"
}
]
},
"operatingsystem_support": [
{
"operatingsystem": "CentOS",
"operatingsystemrelease": [
"6",
"7"
"7",
"8"
]
},
{
"operatingsystem": "RedHat",
"operatingsystemrelease": [
"6",
"7"
"7",
"8"
]
},
{
"operatingsystem": "OracleLinux",
"operatingsystemrelease": [
"6",
"7"
"7",
"8"
]
}
],
Expand Down
23 changes: 12 additions & 11 deletions spec/acceptance/nodesets/default.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,27 +6,28 @@
end
-%>
HOSTS:
el6:
roles:
- default
- master
- client
platform: el-6-x86_64
box: centos/6
hypervisor: <%= hypervisor %>

el7:
roles:
- client
- default
platform: el-7-x86_64
box: centos/7
hypervisor: <%= hypervisor %>
yum_repos:
chef-current:
baseurl: 'https://packages.chef.io/repos/yum/current/el/7/$basearch'
baseurl: 'https://packages.chef.io/repos/yum/current/el/$releasever/$basearch'
gpgkeys:
- https://packages.chef.io/chef.asc

el6:
platform: el-6-x86_64
box: centos/6
hypervisor: <%= hypervisor %>

el8:
platform: el-8-x86_64
box: centos/8
hypervisor: <%= hypervisor %>

CONFIG:
log_level: verbose
type: aio
Expand Down
1 change: 1 addition & 0 deletions types/inetprotocols.pp
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
# Allowed inet protocol settings
type Postfix::InetProtocols = Array[Enum['all','ipv4','ipv6']]
1 change: 1 addition & 0 deletions types/manciphers.pp
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
# Allowed mandatory ciphers
type Postfix::ManCiphers = Enum['export','low','medium','high','null']

0 comments on commit b8905db

Please sign in to comment.