Skip to content

Commit

Permalink
Fix tests and update meta files
Browse files Browse the repository at this point in the history
Fix README
  • Loading branch information
edestecd committed Jul 30, 2017
1 parent 8f02c6e commit 2b84954
Show file tree
Hide file tree
Showing 7 changed files with 47 additions and 68 deletions.
21 changes: 11 additions & 10 deletions .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,30 +20,31 @@ AllCops:
- 'vendor/**/*'
DisplayCopNames: true

#################### Style ##################################
#################### Layout ###############################

# The shebang stuff at the top triggers this
Layout/LeadingCommentSpace:
Exclude:
- Puppetfile

#################### Style ###############################

# Cop supports --auto-correct.
# Configuration parameters: SupportedStyles.
# Support ruby 1.8.7
Style/HashSyntax:
EnforcedStyle: hash_rockets

# The shebang stuff at the top triggers this
Style/LeadingCommentSpace:
Exclude:
- Puppetfile

#################### Metrics ################################
#################### Metrics ###############################

Metrics/LineLength:
# Ruduce this... Max: 80
Max: 112

Metrics/BlockLength:
# Ruduce this... Max: 25
Max: 27
Enabled: false

##################### Bundler #############################
##################### Bundler ##############################

Bundler/DuplicatedGem:
Enabled: false
2 changes: 1 addition & 1 deletion .ruby-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2.1.10
2.1.9
8 changes: 1 addition & 7 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,7 @@ sudo: false
matrix:
fast_finish: true
include:
- rvm: 1.9.3
env: PUPPET_GEM_VERSION="~> 3.0"
- rvm: 1.9.3
env: PUPPET_GEM_VERSION="~> 3.0" FUTURE_PARSER="yes"
- rvm: 2.1.10
env: PUPPET_GEM_VERSION="~> 3.0" FUTURE_PARSER="yes"
- rvm: 2.1.10
- rvm: 2.1.9
env: PUPPET_GEM_VERSION="~> 4.0" STRICT_VARIABLES="yes"
notifications:
email: false
20 changes: 4 additions & 16 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,7 @@ group :unit_tests do
gem 'puppet-lint-version_comparison-check', :require => false
gem 'puppetlabs_spec_helper', :require => false
gem 'rspec-puppet-facts', :require => false
gem 'rubocop', '~> 0.41.2', :require => false if RUBY_VERSION =~ /^1\.9/
gem 'rubocop', :require => false if RUBY_VERSION =~ /^2\./
gem 'rubocop', :require => false
end

group :development do
Expand All @@ -37,22 +36,11 @@ group :development do
end

group :system_tests do
if RUBY_VERSION < '2.2.5'
# beaker 3.1+ requires ruby 2.2.5. Lock to 2.0
gem 'beaker', '~> 2.0', :require => false
# beaker-rspec 6.0.0 requires beaker 3.0. Lock to 5.0
gem 'beaker-rspec', '~> 5.0', :require => false
else
gem 'beaker-rspec', :require => false
end
gem 'serverspec', :require => false
gem 'beaker-rspec', :require => false
gem 'serverspec', :require => false
# gem 'vagrant-wrapper', :require => false
end

# json_pure 2.0.2 added a requirement on ruby >= 2. We pin to json_pure 2.0.1
# if using ruby 1.x
gem 'json_pure', '<= 2.0.1', :require => false if RUBY_VERSION =~ /^1\./

if (facterversion = ENV['FACTER_GEM_VERSION'])
gem 'facter', facterversion, :require => false
else
Expand All @@ -62,7 +50,7 @@ end
if (puppetversion = ENV['PUPPET_GEM_VERSION'])
gem 'puppet', puppetversion, :require => false
else
gem 'puppet', '~> 3.8', :require => false
gem 'puppet', '~> 4.10', :require => false
end

# vim:ft=ruby
34 changes: 17 additions & 17 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ clamav
[![Puppet Forge Downloads](https://img.shields.io/puppetforge/dt/edestecd/clamav.svg)](https://forge.puppet.com/edestecd/clamav)
[![Puppet Forge Score](https://img.shields.io/puppetforge/f/edestecd/clamav.svg)](https://forge.puppet.com/edestecd/clamav/scores)

####Table of Contents
#### Table of Contents

1. [Overview](#overview)
2. [Module Description - What the module does and why it is useful](#module-description)
Expand All @@ -20,11 +20,11 @@ clamav
6. [Development - Guide for contributing to the module](#development)
7. [Contributors](#contributors)

##Overview
## Overview

Puppet Module to install/configure clamd and freshclam on Debian and RedHat

##Module Description
## Module Description

The clamav module provides some classes to install and configure most of the components of clamav.
You may also choose to manage only the parts that you need.
Expand All @@ -38,31 +38,31 @@ This module has the following components that can be managed (or not):
* freshclam daemon/cron (dependent on OS)
* clamav-milter (RHEL7 and derivatives only for now)

##Setup
## Setup

###What clamav affects
### What clamav affects

* clamav/clamd/freshclam package install
* clamav/clamd/freshclam config files
* clamd/freshclam services or daily cron on redhat
* clamav-milter package install, config files, service (optional)
* clam user/group (optional)

###Setup Requirements
### Setup Requirements

only need to install the module

###Beginning with clamav
### Beginning with clamav

Minimal clamav package install for command line use:

```puppet
include clamav
```

##Usage
## Usage

###Manage the clam and freshclam daemon with stock config
### Manage the clam and freshclam daemon with stock config

```puppet
class { 'clamav':
Expand All @@ -73,7 +73,7 @@ class { 'clamav':
}
```

###Also manage the clam user and group
### Also manage the clam user and group

```puppet
class { 'clamav':
Expand All @@ -86,7 +86,7 @@ class { 'clamav':
}
```

###Customize the clamd and freshclam config
### Customize the clamd and freshclam config

```puppet
class { 'clamav':
Expand All @@ -109,8 +109,8 @@ class { 'clamav':
}
```

###Add clamav-milter support and customize its config (RHEL7 and derivatives only)
####Please note that as of RHEL 7.2 only the TCP socket has been tested successfully
### Add clamav-milter support and customize its config (RHEL7 and derivatives only)
#### Please note that as of RHEL 7.2 only the TCP socket has been tested successfully

```puppet
class { 'clamav':
Expand All @@ -133,7 +133,7 @@ class { 'clamav':
}
```

###Configure with hiera yaml
### Configure with hiera yaml

```puppet
include clamav
Expand All @@ -156,7 +156,7 @@ clamav::freshclam_options:
- clam.host2.mydomain.com
```
##Reference
## Reference
### Classes
Expand All @@ -165,14 +165,14 @@ clamav::freshclam_options:
* clamav::clamd
* clamav::freshclam
##Limitations
## Limitations
This module has been built on and tested against Puppet 3.8 and higher.
While I am sure other versions work, I have not tested them.
This module supports modern RedHat and Debian based systems.
No plans to support other versions (unless you add it :)..
##Development
## Development
Pull Requests welcome
22 changes: 11 additions & 11 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ exclude_paths = [
Rake::Task[:lint].clear
PuppetLint::RakeTask.new :lint do |config|
config.ignore_paths = exclude_paths
config.disable_checks = %w(class_inherits_from_params_class 80chars)
config.disable_checks = %w[class_inherits_from_params_class 80chars]
config.fail_on_warnings = true
end
# Puppet-Lint 1.1.0 as well ...
Expand Down Expand Up @@ -48,17 +48,17 @@ task :success do
end

desc 'Run all'
task :all => [
:clean,
:test,
:success
task :all => %i[
clean
test
success
]

desc 'Run rubocop, syntax, lint, and spec tests'
task :test => [
:rubocop,
:syntax,
:lint,
:metadata_lint,
:spec
task :test => %i[
rubocop
syntax
lint
metadata_lint
spec
]
8 changes: 2 additions & 6 deletions metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,18 +28,14 @@
},
{
"operatingsystem": "Debian",
"operatingsystemrelease": ["7", "8"]
"operatingsystemrelease": ["8", "9"]
},
{
"operatingsystem": "Ubuntu",
"operatingsystemrelease": ["12.04", "14.04"]
"operatingsystemrelease": ["14.04", "16.04"]
}
],
"requirements": [
{
"name": "pe",
"version_requirement": ">= 3.0.0 < 5.0.0"
},
{
"name": "puppet",
"version_requirement": ">= 3.0.0 < 5.0.0"
Expand Down

0 comments on commit 2b84954

Please sign in to comment.