-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
98 changed files
with
3,422 additions
and
318 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
APT::Periodic::Enable "0"; | ||
APT::Periodic::Update-Package-Lists "0"; | ||
APT::Periodic::Download-Upgradeable-Packages "0"; | ||
APT::Periodic::AutocleanInterval "0"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
APT::Periodic::Update-Package-Lists "0"; | ||
APT::Periodic::Unattended-Upgrade "0"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
enabled=0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
# This Source Code Form is subject to the terms of the Mozilla Public | ||
# License, v. 2.0. If a copy of the MPL was not distributed with this | ||
# file, You can obtain one at http://mozilla.org/MPL/2.0/. | ||
|
||
class disable_services() { | ||
case $::operatingsystem { | ||
'Ubuntu': { | ||
# These packages are required by ubuntu-desktop, so we can't uninstall them. | ||
# Instead, install but disable them. | ||
case $::operatingsystemrelease { | ||
'18.04': { | ||
# acpi removed because it can't be disabled this way | ||
# (never worked in build-puppet/16.04) | ||
$install_and_disable = [ 'cups', 'anacron', | ||
'whoopsie', 'modemmanager', 'apport', | ||
'avahi-daemon', 'network-manager' ] | ||
package { | ||
$install_and_disable: | ||
ensure => latest; | ||
} | ||
service { | ||
$install_and_disable: | ||
ensure => stopped, | ||
provider => 'systemd', | ||
enable => false, | ||
require => Package[$install_and_disable]; | ||
} | ||
|
||
# disable apport via defaults also | ||
file { | ||
'/etc/default/apport': | ||
source => "puppet:///modules/${module_name}/apport"; | ||
} | ||
|
||
# this package and service have different names | ||
package { | ||
'bluez': | ||
ensure => latest; | ||
} | ||
service { | ||
'bluetooth': | ||
ensure => stopped, | ||
provider => 'systemd', | ||
enable => false, | ||
require => Package['bluez']; | ||
} | ||
|
||
# disable periodic apt actions | ||
file { | ||
'/etc/apt/apt.conf.d/10periodic': | ||
ensure => file, | ||
owner => 'root', | ||
group => 'root', | ||
source => "puppet:///modules/${module_name}/10periodic"; | ||
|
||
'/etc/apt/apt.conf.d/20auto-upgrades': | ||
ensure => file, | ||
owner => 'root', | ||
group => 'root', | ||
source => "puppet:///modules/${module_name}/20auto-upgrades"; | ||
} | ||
|
||
# stop 'unattended-upgrades' processes, disabled in /etc/apt/apt.conf.d/20auto-upgrades | ||
# but still showing up | ||
service { 'unattended-upgrades': | ||
ensure => stopped, | ||
enable => false, | ||
} | ||
} | ||
default: { | ||
fail("Unrecognized Ubuntu version ${::operatingsystemrelease}") | ||
} | ||
} | ||
} | ||
default: { | ||
fail("gui is not supported on ${::operatingsystem}") | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
# This Source Code Form is subject to the terms of the Mozilla Public | ||
# License, v. 2.0. If a copy of the MPL was not distributed with this | ||
# file, You can obtain one at http://mozilla.org/MPL/2.0/. | ||
class grub ( | ||
# dhouse is testing grub logging, but not working yet | ||
$log_aggregator_host = 'log-aggregator2.srv.releng.mdc2.mozilla.com', | ||
$log_aggregator_port = 514, | ||
){ | ||
case $::operatingsystem { | ||
'Ubuntu': { | ||
case $::operatingsystemrelease { | ||
'18.04': { | ||
|
||
# 1804/lvm/efi has issues with setting a timeout. | ||
# - we set GRUB_RECORDFAIL_TIMEOUT to work around this. | ||
# | ||
# more info: | ||
# - https://forums.linuxmint.com/viewtopic.php?f=46&t=287026#p1588204 | ||
# - https://askubuntu.com/questions/1164407/grub-is-ignoring-settings-in-etc-default-grub-single-boot-system | ||
|
||
package { | ||
'grub2-common': | ||
ensure => present; | ||
} | ||
file { | ||
'/etc/default/grub': | ||
ensure => present, | ||
content => template('grub/default-grub.erb'), | ||
notify => Exec['update-grub']; | ||
} | ||
exec { 'update-grub': | ||
command => '/usr/sbin/update-grub', | ||
subscribe => File['/etc/default/grub'], | ||
refreshonly => true, | ||
} | ||
} | ||
default: { | ||
fail("cannot install on ${::operatingsystemrelease}") | ||
} | ||
} | ||
} | ||
default: { | ||
fail("cannot install on ${::operatingsystem}") | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
# If you change this file, run 'update-grub' afterwards to update | ||
# /boot/grub/grub.cfg. | ||
# For full documentation of the options in this file, see: | ||
# info -f grub -n 'Simple configuration' | ||
|
||
GRUB_DEFAULT=0 | ||
GRUB_TIMEOUT_STYLE=menu | ||
GRUB_TIMEOUT=10 | ||
GRUB_RECORDFAIL_TIMEOUT=10 # EFI/LVM uses this for all boots | ||
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian` | ||
GRUB_CMDLINE_LINUX_DEFAULT="" | ||
# notes on grub options | ||
# - 'dis_ucode_ldr': makes certain problematic moonshot nodes boot, otherwise they hang at purple screen | ||
# - 'debug': debug output for developers, potentially alarming in a red herring way | ||
GRUB_CMDLINE_LINUX="nosplash console=ttyS0,9600n8r console=tty0 log_host=<%= @log_aggregator_host %> log_port=<%= @log_aggregator_port %> dis_ucode_ldr" | ||
|
||
# from build-puppet | ||
# | ||
# GRUB_HIDDEN_TIMEOUT=0 | ||
# GRUB_HIDDEN_TIMEOUT_QUIET=true | ||
# GRUB_TIMEOUT=10 | ||
# GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian` | ||
|
||
# Uncomment to enable BadRAM filtering, modify to suit your needs | ||
# This works with Linux (no patch required) and with any kernel that obtains | ||
# the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...) | ||
#GRUB_BADRAM="0x01234567,0xfefefefe,0x89abcdef,0xefefefef" | ||
|
||
# Uncomment to disable graphical terminal (grub-pc only) | ||
#GRUB_TERMINAL=console | ||
|
||
# The resolution used on graphical terminal | ||
# note that you can use only modes which your graphic card supports via VBE | ||
# you can see them in real GRUB with the command `vbeinfo' | ||
#GRUB_GFXMODE=640x480 | ||
|
||
# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux | ||
#GRUB_DISABLE_LINUX_UUID=true | ||
|
||
# Uncomment to disable generation of recovery mode menu entries | ||
#GRUB_DISABLE_RECOVERY="true" | ||
|
||
# Uncomment to get a beep at grub start | ||
#GRUB_INIT_TUNE="480 440 1" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
# If you change this file, run 'update-grub' afterwards to update | ||
# /boot/grub/grub.cfg. | ||
# For full documentation of the options in this file, see: | ||
# info -f grub -n 'Simple configuration' | ||
|
||
GRUB_DEFAULT=0 | ||
GRUB_TIMEOUT_STYLE=hidden | ||
GRUB_TIMEOUT=0 | ||
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian` | ||
GRUB_CMDLINE_LINUX_DEFAULT="quiet" | ||
GRUB_CMDLINE_LINUX="nosplash debug console=ttyS0,9600n8r console=tty0" | ||
|
||
# Uncomment to enable BadRAM filtering, modify to suit your needs | ||
# This works with Linux (no patch required) and with any kernel that obtains | ||
# the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...) | ||
#GRUB_BADRAM="0x01234567,0xfefefefe,0x89abcdef,0xefefefef" | ||
|
||
# Uncomment to disable graphical terminal (grub-pc only) | ||
#GRUB_TERMINAL=console | ||
|
||
# The resolution used on graphical terminal | ||
# note that you can use only modes which your graphic card supports via VBE | ||
# you can see them in real GRUB with the command `vbeinfo' | ||
#GRUB_GFXMODE=640x480 | ||
|
||
# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux | ||
#GRUB_DISABLE_LINUX_UUID=true | ||
|
||
# Uncomment to disable generation of recovery mode menu entries | ||
#GRUB_DISABLE_RECOVERY="true" | ||
|
||
# Uncomment to get a beep at grub start | ||
#GRUB_INIT_TUNE="480 440 1" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.