Commit 09af3e05 authored by Karl Kornel's avatar Karl Kornel
Browse files

os::debian: Modify sources file last

Hold off on modifying the main sources file until
we’ve created all our other sources files.
parent 3188c8af
......@@ -66,10 +66,11 @@ class base::os::debian (
# Install APT sources configuration. This is generally handled via
# templates.
# NOTE: We hold off on messing with the master sources list until we've
# created the other sources files. We do this to ensure that a source
# never gets removed entirely. Luckily, `aptitude update` doesn't error
# out if a source is listed multiple times.
file {
'/etc/apt/sources.list':
content => template('base/os/sources/sources.list.erb'),
notify => Exec['aptitude update'];
'/etc/apt/sources.list.d':
ensure => 'directory',
recurse => true,
......@@ -81,6 +82,13 @@ class base::os::debian (
'/etc/apt/sources.list.d/stanford.list':
content => template('base/os/sources/stanford.list.erb'),
notify => Exec['aptitude update'];
'/etc/apt/sources.list':
content => template('base/os/sources/sources.list.erb'),
require => [
File['/etc/apt/sources.list.d/backports.list'],
File['/etc/apt/sources.list.d/stanford.list'],
],
notify => Exec['aptitude update'];
}
# Install APT preferences. We should never use /etc/apt/preferences
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment