Skip to content
Snippets Groups Projects
Commit 6a62c8f7 authored by Micah's avatar Micah
Browse files

Merge commit '38cf1269' as 'puppet/modules/systemd'

parents 783f953a 38cf1269
No related branches found
No related tags found
No related merge requests found
Showing
with 475 additions and 0 deletions
pkg/
Gemfile.lock
vendor/
spec/fixtures/
.vagrant/
.bundle/
coverage/
log/
.*.swp
*~
--fail-on-warnings
--relative
--no-80chars
--no-documentation
--no-class_inherits_from_params_class-check
---
.travis.yml:
forge_password: "ASTRdmLjJNa1NvHy2LRGvmvUeth6W3Fh/alYWvcvI8nDDsdkweHk0iXhcXZwtMQReb0NI5vJiRNXNy7a3XySC4+SP3hfHuDU58H2FqC4Ff0EHRPRHTEiXf7xmN53RxXYXZQvrFfqUb6tIsBNVKVmsYWNe01k8NVKPyYDfQB75PQ="
---
language: ruby
sudo: false
cache: bundler
bundler_args: --without system_tests
script: ["bundle exec rake validate", "bundle exec rake lint", "bundle exec rake spec SPEC_OPTS='--format documentation'", "bundle exec rake metadata"]
matrix:
fast_finish: true
include:
- rvm: 1.8.7
env: PUPPET_GEM_VERSION="~> 3.0" FACTER_GEM_VERSION="~> 1.7.0"
- rvm: 1.9.3
env: PUPPET_GEM_VERSION="~> 3.0"
- rvm: 2.0.0
env: PUPPET_GEM_VERSION="~> 3.0"
- rvm: 2.0.0
env: PUPPET_GEM_VERSION="~> 3.0" FUTURE_PARSER="yes"
- rvm: 2.1.6
env: PUPPET_GEM_VERSION="~> 4.0"
notifications:
email: false
deploy:
provider: puppetforge
user: camptocamp
password:
secure: "ASTRdmLjJNa1NvHy2LRGvmvUeth6W3Fh/alYWvcvI8nDDsdkweHk0iXhcXZwtMQReb0NI5vJiRNXNy7a3XySC4+SP3hfHuDU58H2FqC4Ff0EHRPRHTEiXf7xmN53RxXYXZQvrFfqUb6tIsBNVKVmsYWNe01k8NVKPyYDfQB75PQ="
on:
tags: true
# all_branches is required to use tags
all_branches: true
# Only publish if our main Ruby target builds
rvm: 1.9.3
# Change Log
## [0.2.2](https://forge.puppetlabs.com/camptocamp/systemd/0.2.2) (2015-08-25)
[Full Changelog](https://github.com/camptocamp/puppet-systemd/compare/0.2.1...0.2.2)
**Implemented enhancements:**
- Add 'systemd-tmpfiles-create' [\#1](https://github.com/camptocamp/puppet-systemd/pull/1) ([roidelapluie](https://github.com/roidelapluie))
## [0.2.1](https://forge.puppetlabs.com/camptocamp/systemd/0.2.1) (2015-08-21)
[Full Changelog](https://github.com/camptocamp/puppet-systemd/compare/0.2.0...0.2.1)
- Use docker for acceptance tests
## [0.1.15](https://forge.puppetlabs.com/camptocamp/systemd/0.1.15) (2015-06-26)
[Full Changelog](https://github.com/camptocamp/puppet-systemd/compare/0.1.14...0.1.15)
- Fix strict_variables activation with rspec-puppet 2.2
## [0.1.14](https://forge.puppetlabs.com/camptocamp/systemd/0.1.14) (2015-05-28)
[Full Changelog](https://github.com/camptocamp/puppet-systemd/compare/0.1.13...0.1.14)
- Add beaker_spec_helper to Gemfile
## [0.1.13](https://forge.puppetlabs.com/camptocamp/systemd/0.1.13) (2015-05-26)
[Full Changelog](https://github.com/camptocamp/puppet-systemd/compare/0.1.12...0.1.13)
- Use random application order in nodeset
## [0.1.12](https://forge.puppetlabs.com/camptocamp/systemd/0.1.12) (2015-05-26)
[Full Changelog](https://github.com/camptocamp/puppet-systemd/compare/0.1.11...0.1.12)
- Add utopic & vivid nodesets
## [0.1.11](https://forge.puppetlabs.com/camptocamp/systemd/0.1.11) (2015-05-25)
[Full Changelog](https://github.com/camptocamp/puppet-systemd/compare/0.1.10...0.1.11)
- Don't allow failure on Puppet 4
## [0.1.10](https://forge.puppetlabs.com/camptocamp/systemd/0.1.10) (2015-05-13)
[Full Changelog](https://github.com/camptocamp/puppet-systemd/compare/0.1.9...0.1.10)
- Add puppet-lint-file_source_rights-check gem
## [0.1.9](https://forge.puppetlabs.com/camptocamp/systemd/0.1.9) (2015-05-12)
[Full Changelog](https://github.com/camptocamp/puppet-systemd/compare/0.1.8...0.1.9)
- Don't pin beaker
## [0.1.8](https://forge.puppetlabs.com/camptocamp/systemd/0.1.8) (2015-04-27)
[Full Changelog](https://github.com/camptocamp/puppet-systemd/compare/0.1.7...0.1.8)
- Add nodeset ubuntu-12.04-x86_64-openstack
## [0.1.7](https://forge.puppetlabs.com/camptocamp/systemd/0.1.7) (2015-04-03)
[Full Changelog](https://github.com/camptocamp/puppet-systemd/compare/0.1.6...0.1.7)
- Confine rspec pinning to ruby 1.8
\* *This Change Log was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)*
\* *This Change Log was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)*
\ No newline at end of file
source ENV['GEM_SOURCE'] || "https://rubygems.org"
group :development, :unit_tests do
gem 'rake', :require => false
gem 'rspec', '< 3.2', :require => false if RUBY_VERSION =~ /^1.8/
gem 'rspec-puppet', :require => false
gem 'puppetlabs_spec_helper', :require => false
gem 'metadata-json-lint', :require => false
gem 'puppet-lint', :require => false
gem 'puppet-lint-unquoted_string-check', :require => false
gem 'puppet-lint-empty_string-check', :require => false
gem 'puppet-lint-spaceship_operator_without_tag-check', :require => false
gem 'puppet-lint-variable_contains_upcase', :require => false
gem 'puppet-lint-absolute_classname-check', :require => false
gem 'puppet-lint-undef_in_function-check', :require => false
gem 'puppet-lint-leading_zero-check', :require => false
gem 'puppet-lint-trailing_comma-check', :require => false
gem 'puppet-lint-file_ensure-check', :require => false
gem 'puppet-lint-version_comparison-check', :require => false
gem 'puppet-lint-fileserver-check', :require => false
gem 'puppet-lint-file_source_rights-check', :require => false
gem 'puppet-lint-alias-check', :require => false
gem 'rspec-puppet-facts', :require => false
gem 'github_changelog_generator', :require => false, :git => 'https://github.com/raphink/github-changelog-generator.git', :branch => 'dev/all_patches' if RUBY_VERSION !~ /^1.8/
gem 'puppet-blacksmith', :require => false if RUBY_VERSION !~ /^1.8/
end
group :system_tests do
gem 'beaker', :require => false
gem 'beaker-rspec', :require => false
gem 'beaker_spec_helper', :require => false
gem 'serverspec', :require => false
end
if facterversion = ENV['FACTER_GEM_VERSION']
gem 'facter', facterversion, :require => false
else
gem 'facter', :require => false
end
if puppetversion = ENV['PUPPET_GEM_VERSION']
gem 'puppet', puppetversion, :require => false
else
gem 'puppet', :require => false
end
# vim:ft=ruby
## [0.2.2](https://forge.puppetlabs.com/camptocamp/systemd/0.2.2) (2015-08-25)
[Full Changelog](https://github.com/camptocamp/puppet-systemd/compare/0.2.1...0.2.2)
**Implemented enhancements:**
- Add 'systemd-tmpfiles-create' [\#1](https://github.com/camptocamp/puppet-systemd/pull/1) ([roidelapluie](https://github.com/roidelapluie))
## [0.2.1](https://forge.puppetlabs.com/camptocamp/systemd/0.2.1) (2015-08-21)
[Full Changelog](https://github.com/camptocamp/puppet-systemd/compare/0.2.0...0.2.1)
- Use docker for acceptance tests
## [0.1.15](https://forge.puppetlabs.com/camptocamp/systemd/0.1.15) (2015-06-26)
[Full Changelog](https://github.com/camptocamp/puppet-systemd/compare/0.1.14...0.1.15)
- Fix strict_variables activation with rspec-puppet 2.2
## [0.1.14](https://forge.puppetlabs.com/camptocamp/systemd/0.1.14) (2015-05-28)
[Full Changelog](https://github.com/camptocamp/puppet-systemd/compare/0.1.13...0.1.14)
- Add beaker_spec_helper to Gemfile
## [0.1.13](https://forge.puppetlabs.com/camptocamp/systemd/0.1.13) (2015-05-26)
[Full Changelog](https://github.com/camptocamp/puppet-systemd/compare/0.1.12...0.1.13)
- Use random application order in nodeset
## [0.1.12](https://forge.puppetlabs.com/camptocamp/systemd/0.1.12) (2015-05-26)
[Full Changelog](https://github.com/camptocamp/puppet-systemd/compare/0.1.11...0.1.12)
- Add utopic & vivid nodesets
## [0.1.11](https://forge.puppetlabs.com/camptocamp/systemd/0.1.11) (2015-05-25)
[Full Changelog](https://github.com/camptocamp/puppet-systemd/compare/0.1.10...0.1.11)
- Don't allow failure on Puppet 4
## [0.1.10](https://forge.puppetlabs.com/camptocamp/systemd/0.1.10) (2015-05-13)
[Full Changelog](https://github.com/camptocamp/puppet-systemd/compare/0.1.9...0.1.10)
- Add puppet-lint-file_source_rights-check gem
## [0.1.9](https://forge.puppetlabs.com/camptocamp/systemd/0.1.9) (2015-05-12)
[Full Changelog](https://github.com/camptocamp/puppet-systemd/compare/0.1.8...0.1.9)
- Don't pin beaker
## [0.1.8](https://forge.puppetlabs.com/camptocamp/systemd/0.1.8) (2015-04-27)
[Full Changelog](https://github.com/camptocamp/puppet-systemd/compare/0.1.7...0.1.8)
- Add nodeset ubuntu-12.04-x86_64-openstack
## [0.1.7](https://forge.puppetlabs.com/camptocamp/systemd/0.1.7) (2015-04-03)
[Full Changelog](https://github.com/camptocamp/puppet-systemd/compare/0.1.6...0.1.7)
- Confine rspec pinning to ruby 1.8
\* *This Change Log was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)*
\* *This Change Log was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)*
# Systemd
[![Puppet Forge](http://img.shields.io/puppetforge/v/camptocamp/systemd.svg)](https://forge.puppetlabs.com/camptocamp/systemd)
[![Build Status](https://travis-ci.org/camptocamp/puppet-systemd.png?branch=master)](https://travis-ci.org/camptocamp/puppet-systemd)
## Overview
This module declares exec resources that you can use when you change systemd units or configuration files.
## Examples
### systemctl --daemon-reload
```puppet
include ::systemd
file { '/usr/lib/systemd/system/foo.service':
ensure => file,
owner => 'root',
group => 'root',
mode => '0644',
source => "puppet:///modules/${module_name}/foo.service",
} ~>
Exec['systemctl-daemon-reload']
```
### systemd-tmpfiles --create
```puppet
include ::systemd
file { '/etc/tmpfiles.d/foo.conf':
ensure => file,
owner => 'root',
group => 'root',
mode => '0644',
source => "puppet:///modules/${module_name}/foo.conf",
} ~>
Exec['systemd-tmpfiles-create']
```
require 'puppetlabs_spec_helper/rake_tasks'
require 'puppet-lint/tasks/puppet-lint'
Rake::Task[:lint].clear
PuppetLint::RakeTask.new :lint do |config|
config.ignore_paths = ["spec/**/*.pp", "pkg/**/*.pp", "vendor/**/*.pp"]
config.disable_checks = ['80chars']
config.fail_on_warnings = true
end
PuppetSyntax.exclude_paths = ["spec/fixtures/**/*.pp", "vendor/**/*"]
# Publishing tasks
unless RUBY_VERSION =~ /^1\.8/
require 'puppet_blacksmith'
require 'puppet_blacksmith/rake_tasks'
require 'github_changelog_generator/task'
GitHubChangelogGenerator::RakeTask.new :changelog do |config|
m = Blacksmith::Modulefile.new
config.future_release = m.version
config.release_url = "https://forge.puppetlabs.com/#{m.author}/#{m.name}/%s"
end
end
class systemd {
Exec {
refreshonly => true,
path => $::path,
}
exec {
'systemctl-daemon-reload':
command => 'systemctl daemon-reload',
}
exec {
'systemd-tmpfiles-create':
command => 'systemd-tmpfiles --create',
}
}
{
"name": "camptocamp-systemd",
"version": "0.2.2",
"author": "camptocamp",
"summary": "Puppet Systemd module",
"license": "Apache-2.0",
"source": "https://github.com/camptocamp/puppet-systemd",
"project_page": "https://github.com/camptocamp/puppet-systemd",
"issues_url": "https://github.com/camptocamp/puppet-systemd/issues",
"dependencies": [
],
"requirements": [
{
"name": "pe",
"version_requirement": "3.x"
},
{
"name": "puppet",
"version_requirement": "3.x"
}
],
"operatingsystem_support": [
{
"operatingsystem": "Debian",
"operatingsystemrelease": [
"8"
]
},
{
"operatingsystem": "RedHat",
"operatingsystemrelease": [
"7"
]
}
],
"puppet_version": [
"2.7",
"3.0",
"3.1",
"3.2",
"3.3",
"3.4",
"3.5",
"3.6",
"3.7"
]
}
HOSTS:
centos-5-x64:
default_apply_opts:
order: random
strict_variables:
platform: el-5-x86_64
hypervisor : docker
image: centos:5
docker_preserve_image: true
docker_cmd: '["/sbin/init"]'
docker_image_commands:
- 'yum install -y crontabs tar wget'
CONFIG:
type: foss
log_level: debug
HOSTS:
centos-6-x64:
default_apply_opts:
order: random
strict_variables:
platform: el-6-x86_64
hypervisor : docker
image: centos:6
docker_preserve_image: true
docker_cmd: '["/sbin/init"]'
docker_image_commands:
- 'yum install -y crontabs tar wget'
CONFIG:
type: foss
log_level: debug
HOSTS:
centos-6-x64:
default_apply_opts:
order: random
strict_variables:
platform: el-6-x86_64
hypervisor : openstack
flavor: m1.small
image: centos-6-latest
user: root
CONFIG:
type: foss
log_level: debug
openstack_network: default
HOSTS:
centos-6-x64:
default_apply_opts:
order: random
strict_variables:
platform: el-6-x86_64
hypervisor : vagrant
box : camptocamp/centos-6-x86_64
CONFIG:
type: foss
log_level: debug
HOSTS:
centos-7-x64:
default_apply_opts:
order: random
strict_variables:
platform: el-7-x86_64
hypervisor : docker
image: centos:7
docker_preserve_image: true
docker_cmd: '["/usr/sbin/init"]'
docker_image_commands:
- 'yum install -y crontabs tar wget'
CONFIG:
type: foss
log_level: debug
HOSTS:
centos-7-x64:
default_apply_opts:
order: random
strict_variables:
platform: el-7-x86_64
hypervisor : openstack
flavor: m1.small
image: centos-7-latest
user: centos
CONFIG:
type: foss
log_level: debug
openstack_network: default
HOSTS:
centos-7-x64:
default_apply_opts:
order: random
strict_variables:
platform: el-7-x86_64
hypervisor : vagrant
box : camptocamp/centos-7-x86_64
CONFIG:
type: foss
log_level: debug
HOSTS:
debian-6-x64:
default_apply_opts:
order: random
strict_variables:
platform: debian-6-amd64
hypervisor : docker
image: debian:6
docker_preserve_image: true
docker_cmd: '["/sbin/init"]'
docker_image_commands:
- 'apt-get install -y wget'
CONFIG:
type: foss
log_level: debug
HOSTS:
debian-6-x64:
default_apply_opts:
order: random
strict_variables:
platform: debian-6-amd64
hypervisor : openstack
flavor: m1.small
image: debian-6-latest
user: debian
CONFIG:
type: foss
log_level: debug
openstack_network: default
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment