summaryrefslogtreecommitdiff
path: root/manifests
diff options
context:
space:
mode:
authorHugo Hörnquist <hugo@lysator.liu.se>2022-01-24 11:11:45 +0100
committerHugo Hörnquist <hugo@lysator.liu.se>2022-02-09 18:06:12 +0100
commit7f9786da29b414d94af99c77be7fe16a6e919fba (patch)
tree29b378d810ccc0977d90a1eb86a01305a322b3b8 /manifests
parentprofiles::puppetagent add extra_args param. (diff)
downloadprofiles-7f9786da29b414d94af99c77be7fe16a6e919fba.tar.gz
profiles-7f9786da29b414d94af99c77be7fe16a6e919fba.tar.xz
Broke profiles into parts.
Diffstat (limited to 'manifests')
-rw-r--r--manifests/repo.pp12
-rw-r--r--manifests/sudo.pp17
-rw-r--r--manifests/workstation.pp15
-rw-r--r--manifests/workstation/family/archlinux.pp6
4 files changed, 32 insertions, 18 deletions
diff --git a/manifests/repo.pp b/manifests/repo.pp
new file mode 100644
index 0000000..afe88d2
--- /dev/null
+++ b/manifests/repo.pp
@@ -0,0 +1,12 @@
+# Configure private custom repo for those dists that support it
+class profiles::repo {
+ case $facts['osfamily'] {
+ 'Archlinux': {
+ pacman::repo { 'adrift-space':
+ ensure => present,
+ server => 'http://repo.gandalf.adrift.space/arch',
+ sig_level => 'Optional',
+ }
+ }
+ }
+}
diff --git a/manifests/sudo.pp b/manifests/sudo.pp
new file mode 100644
index 0000000..6b5fe6b
--- /dev/null
+++ b/manifests/sudo.pp
@@ -0,0 +1,17 @@
+class profiles::sudo {
+ file { '/etc/sudoers':
+ validate_cmd => '/usr/bin/visudo -cf %',
+ content => @(EOF)
+ Defaults insults
+ root ALL=(ALL) ALL
+ %root ALL=(ALL) ALL
+ %wheel ALL=(ALL) ALL
+
+ @includedir /etc/sudoers.d
+ | EOF
+ }
+
+ file { '/etc/sudoers.d':
+ ensure => directory,
+ }
+}
diff --git a/manifests/workstation.pp b/manifests/workstation.pp
index 051f3fc..d70fa57 100644
--- a/manifests/workstation.pp
+++ b/manifests/workstation.pp
@@ -12,6 +12,8 @@ class profiles::workstation (
include ::profiles::group_profile
+ include ::profiles::repo
+
if ($facts['systemd']) {
file { 'User ssh-agent service':
path => '/etc/systemd/user/ssh-agent.service',
@@ -119,17 +121,6 @@ class profiles::workstation (
source => 'puppet:///modules/profiles/passmenu',
}
- file { '/etc/sudoers':
- validate_cmd => '/usr/bin/visudo -cf %',
- content => @(EOF)
- Defaults insults
- root ALL=(ALL) ALL
- %root ALL=(ALL) ALL
- %wheel ALL=(ALL) ALL
-
- @includedir /etc/sudoers.d
- | EOF
- }
-
+ include ::profiles::sudo
include ::profiles::mounts
}
diff --git a/manifests/workstation/family/archlinux.pp b/manifests/workstation/family/archlinux.pp
index f84946c..306b903 100644
--- a/manifests/workstation/family/archlinux.pp
+++ b/manifests/workstation/family/archlinux.pp
@@ -24,12 +24,6 @@ class profiles::workstation::family::archlinux {
line => "MAKEFLAGS='-j${cpus}'"
}
- pacman::repo { 'adrift-space':
- ensure => present,
- server => 'http://repo.gandalf.adrift.space/arch',
- sig_level => 'Optional',
- }
-
# remove
# - netctl