Skip to content

Commit 376f73c

Browse files
committed
Merge pull request #20 from datacentred/fix_package_deps
Fix broken package deps
2 parents a21daef + 204c525 commit 376f73c

File tree

4 files changed

+17
-2
lines changed

4 files changed

+17
-2
lines changed

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,10 @@ There's a couple of fairly standard dependencies for this module, as follows:
2222
* https://github.com/puppetlabs/puppetlabs-stdlib
2323
* https://github.com/puppetlabs/puppetlabs-apt (on Debian / Ubuntu)
2424

25+
*NB:* On some apt-based distributions you'll need to ensure you have support
26+
for TLS-enabled repos in place. This can be achieved by installing the
27+
`apt-transport-https` package.
28+
2529
### Usage
2630

2731
Telegraf's configuration is split into four main sections - global tags,

manifests/install.pp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
if $::telegraf::manage_repo {
1313
case $::osfamily {
1414
'Debian': {
15-
ensure_packages(['apt-transport-https'])
1615
apt::source { 'influxdata':
1716
comment => 'Mirror for InfluxData packages',
1817
location => "https://repos.influxdata.com/${_operatingsystem}",
@@ -22,7 +21,6 @@
2221
'id' => '05CE15085FC09D18E99EFB22684A14CF2582E0C5',
2322
'source' => 'https://repos.influxdata.com/influxdb.key',
2423
},
25-
require => Package['apt-transport-https'],
2624
}
2725
Class['apt::update'] -> Package['telegraf']
2826
}
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
HOSTS:
2+
ubuntu-server-1404-x64:
3+
platform: ubuntu-14.04-amd64
4+
box : puppetlabs/ubuntu-14.04-64-nocm
5+
box_url : https://vagrantcloud.com/puppetlabs/ubuntu-14.04-64-nocm
6+
hypervisor : vagrant
7+
CONFIG:
8+
masterless: true
9+
log_level: verbose
10+
type: git

spec/spec_helper_acceptance.rb

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@
2121
puppet_module_install(:source => proj_root, :module_name => 'telegraf')
2222
# Install dependancies
2323
hosts.each do |host|
24+
if fact('osfamily') == 'Debian'
25+
on host, 'apt-get -y install apt-transport-https'
26+
end
2427
on host, puppet('module', 'install', 'puppetlabs-stdlib'), { :acceptable_exit_codes => [0,1] }
2528
on host, puppet('module', 'install', 'puppetlabs-apt'), { :acceptable_exit_codes => [0,1] }
2629
end

0 commit comments

Comments
 (0)