Filip Pytloun | f5383a4 | 2015-10-06 16:28:32 +0200 | [diff] [blame] | 1 | {% set system = salt['grains.filter_by']({ |
| 2 | 'Arch': { |
| 3 | 'pkgs': ['sudo', 'vim', 'wget'], |
| 4 | 'utc': true, |
| 5 | 'user': {}, |
| 6 | 'group': {}, |
| 7 | 'job': {}, |
Filip Pytloun | d0a29e7 | 2015-11-30 15:23:34 +0100 | [diff] [blame] | 8 | 'limit': {}, |
Filip Pytloun | c49445a | 2016-04-04 14:23:20 +0200 | [diff] [blame] | 9 | 'locale': {}, |
Filip Pytloun | e874dfb | 2016-01-22 16:57:34 +0100 | [diff] [blame] | 10 | 'motd': {}, |
Filip Pytloun | f5383a4 | 2015-10-06 16:28:32 +0200 | [diff] [blame] | 11 | 'repo': {}, |
| 12 | 'package': {}, |
Bruno Binet | 69a9d8d | 2017-02-16 22:34:32 +0100 | [diff] [blame^] | 13 | 'autoupdates': { |
| 14 | 'enabled': False, |
| 15 | 'pkgs': [] |
| 16 | }, |
Filip Pytloun | f5383a4 | 2015-10-06 16:28:32 +0200 | [diff] [blame] | 17 | 'selinux': 'permissive', |
| 18 | 'ca_certs_dir': '/usr/local/share/ca-certificates', |
Filip Pytloun | 7589acd | 2016-02-15 16:29:01 +0100 | [diff] [blame] | 19 | 'doc_validity_pkgs': ['python-yaml'], |
Filip Pytloun | f5383a4 | 2015-10-06 16:28:32 +0200 | [diff] [blame] | 20 | }, |
| 21 | 'Debian': { |
Éric Lemoine | 1c39744 | 2016-11-03 10:54:14 +0100 | [diff] [blame] | 22 | 'pkgs': ['python-apt','vim-nox', 'apt-transport-https', 'libmnl0'], |
Filip Pytloun | f5383a4 | 2015-10-06 16:28:32 +0200 | [diff] [blame] | 23 | 'utc': true, |
| 24 | 'user': {}, |
| 25 | 'group': {}, |
| 26 | 'job': {}, |
Filip Pytloun | d0a29e7 | 2015-11-30 15:23:34 +0100 | [diff] [blame] | 27 | 'limit': {}, |
Filip Pytloun | c49445a | 2016-04-04 14:23:20 +0200 | [diff] [blame] | 28 | 'locale': {}, |
Filip Pytloun | e874dfb | 2016-01-22 16:57:34 +0100 | [diff] [blame] | 29 | 'motd': {}, |
Filip Pytloun | f5383a4 | 2015-10-06 16:28:32 +0200 | [diff] [blame] | 30 | 'repo': {}, |
| 31 | 'package': {}, |
Bruno Binet | 69a9d8d | 2017-02-16 22:34:32 +0100 | [diff] [blame^] | 32 | 'autoupdates': { |
| 33 | 'enabled': False, |
| 34 | 'pkgs': ['unattended-upgrades'] |
| 35 | }, |
Filip Pytloun | f5383a4 | 2015-10-06 16:28:32 +0200 | [diff] [blame] | 36 | 'selinux': 'permissive', |
| 37 | 'ca_certs_dir': '/usr/local/share/ca-certificates', |
Filip Pytloun | 7589acd | 2016-02-15 16:29:01 +0100 | [diff] [blame] | 38 | 'doc_validity_pkgs': ['python-yaml'], |
Filip Pytloun | f5383a4 | 2015-10-06 16:28:32 +0200 | [diff] [blame] | 39 | }, |
| 40 | 'RedHat': { |
| 41 | 'pkgs': ['policycoreutils', 'policycoreutils-python', 'vim-enhanced', 'telnet', 'wget'], |
| 42 | 'utc': true, |
| 43 | 'user': {}, |
| 44 | 'group': {}, |
| 45 | 'job': {}, |
Filip Pytloun | d0a29e7 | 2015-11-30 15:23:34 +0100 | [diff] [blame] | 46 | 'limit': {}, |
Filip Pytloun | c49445a | 2016-04-04 14:23:20 +0200 | [diff] [blame] | 47 | 'locale': {}, |
Filip Pytloun | e874dfb | 2016-01-22 16:57:34 +0100 | [diff] [blame] | 48 | 'motd': {}, |
Filip Pytloun | f5383a4 | 2015-10-06 16:28:32 +0200 | [diff] [blame] | 49 | 'repo': {}, |
| 50 | 'package': {}, |
Bruno Binet | 69a9d8d | 2017-02-16 22:34:32 +0100 | [diff] [blame^] | 51 | 'autoupdates': { |
| 52 | 'enabled': False, |
| 53 | 'pkgs': [] |
| 54 | }, |
Filip Pytloun | f5383a4 | 2015-10-06 16:28:32 +0200 | [diff] [blame] | 55 | 'selinux': 'permissive', |
| 56 | 'ca_certs_dir': '/usr/local/share/ca-certificates', |
Filip Pytloun | 7589acd | 2016-02-15 16:29:01 +0100 | [diff] [blame] | 57 | 'doc_validity_pkgs': ['PyYAML'], |
Filip Pytloun | f5383a4 | 2015-10-06 16:28:32 +0200 | [diff] [blame] | 58 | }, |
| 59 | }, grain='os_family', merge=salt['pillar.get']('linux:system')) %} |
| 60 | |
| 61 | {# 'network_name', #} |
| 62 | |
| 63 | {% set interface_params = [ |
| 64 | 'gateway', |
| 65 | 'mtu', |
| 66 | 'network', |
| 67 | 'broadcast', |
| 68 | 'master', |
| 69 | 'miimon', |
Jakub Pavlik | fc60eb0 | 2017-01-03 11:58:12 +0100 | [diff] [blame] | 70 | 'ovs_ports', |
| 71 | 'ovs_bridge', |
Filip Pytloun | f5383a4 | 2015-10-06 16:28:32 +0200 | [diff] [blame] | 72 | 'mode', |
Jakub Pavlik | fc60eb0 | 2017-01-03 11:58:12 +0100 | [diff] [blame] | 73 | 'port_type', |
| 74 | 'peer', |
Filip Pytloun | f5383a4 | 2015-10-06 16:28:32 +0200 | [diff] [blame] | 75 | 'lacp-rate', |
| 76 | 'dns-search', |
| 77 | 'up_cmds', |
| 78 | 'pre_up_cmds', |
| 79 | 'post_up_cmds', |
| 80 | 'down_cmds', |
| 81 | 'pre_down_cmds', |
| 82 | 'post_down_cmds', |
Pavel Cizinsky | 110e574 | 2016-07-12 21:23:46 +0200 | [diff] [blame] | 83 | 'maxwait', |
| 84 | 'stp', |
Jakub Pavlik | 4ad86e0 | 2016-07-12 21:44:31 +0200 | [diff] [blame] | 85 | 'gro', |
Petr Michalec | f0a5fe4 | 2016-10-24 21:08:23 +0200 | [diff] [blame] | 86 | 'lacp_rate', |
| 87 | 'ad_select', |
| 88 | 'downdelay', |
| 89 | 'updelay', |
Petr Michalec | 8824240 | 2016-10-27 09:00:09 +0200 | [diff] [blame] | 90 | 'hashing-algorithm', |
Filip Pytloun | f5383a4 | 2015-10-06 16:28:32 +0200 | [diff] [blame] | 91 | ] %} |
| 92 | |
| 93 | {% set network = salt['grains.filter_by']({ |
| 94 | 'Arch': { |
| 95 | 'pkgs': ['wpa_supplicant', 'dhclient', 'wireless_tools'], |
| 96 | 'bridge_pkgs': ['bridge-utils'], |
| 97 | 'ovs_pkgs': ['openvswitch-switch'], |
| 98 | 'hostname_file': '/etc/hostname', |
| 99 | 'network_manager': False, |
| 100 | 'interface': {}, |
| 101 | 'interface_params': interface_params, |
| 102 | 'bridge': 'none', |
| 103 | 'proxy': { |
| 104 | 'host': 'none', |
| 105 | }, |
| 106 | 'host': {}, |
| 107 | }, |
| 108 | 'Debian': { |
| 109 | 'hostname_file': '/etc/hostname', |
| 110 | 'bridge_pkgs': ['bridge-utils'], |
Ales Komarek | 6086f63 | 2016-11-23 13:28:13 +0100 | [diff] [blame] | 111 | 'ovs_pkgs': ['openvswitch-switch', 'bridge-utils'], |
Filip Pytloun | f5383a4 | 2015-10-06 16:28:32 +0200 | [diff] [blame] | 112 | 'network_manager': False, |
| 113 | 'interface': {}, |
| 114 | 'interface_params': interface_params, |
| 115 | 'bridge': 'none', |
| 116 | 'proxy': { |
| 117 | 'host': 'none', |
| 118 | }, |
| 119 | 'host': {}, |
| 120 | }, |
| 121 | 'RedHat': { |
| 122 | 'bridge_pkgs': ['bridge-utils'], |
Ales Komarek | 6086f63 | 2016-11-23 13:28:13 +0100 | [diff] [blame] | 123 | 'ovs_pkgs': ['openvswitch-switch', 'bridge-utils'], |
Filip Pytloun | f5383a4 | 2015-10-06 16:28:32 +0200 | [diff] [blame] | 124 | 'hostname_file': '/etc/sysconfig/network', |
| 125 | 'network_manager': False, |
| 126 | 'interface': {}, |
| 127 | 'interface_params': interface_params, |
| 128 | 'bridge': 'none', |
| 129 | 'proxy': { |
| 130 | 'host': 'none', |
| 131 | }, |
| 132 | 'host': {}, |
| 133 | }, |
| 134 | }, grain='os_family', merge=salt['pillar.get']('linux:network')) %} |
| 135 | |
| 136 | {% set storage = salt['grains.filter_by']({ |
| 137 | 'Arch': { |
| 138 | 'mount': {}, |
vmikes | 37837f3 | 2017-01-09 10:19:51 +0100 | [diff] [blame] | 139 | 'swap': {}, |
Filip Pytloun | c8a001a | 2015-12-15 14:09:19 +0100 | [diff] [blame] | 140 | 'lvm': {}, |
Simon Pasquier | 375001e | 2017-01-26 13:22:33 +0100 | [diff] [blame] | 141 | 'loopback': {}, |
Ales Komarek | a634f4b | 2016-10-02 13:11:04 +0200 | [diff] [blame] | 142 | 'multipath': { |
| 143 | 'enabled': False, |
| 144 | 'pkgs': ['multipath-tools', 'multipath-tools-boot'], |
| 145 | 'service': '' |
| 146 | }, |
Filip Pytloun | f5383a4 | 2015-10-06 16:28:32 +0200 | [diff] [blame] | 147 | }, |
| 148 | 'Debian': { |
| 149 | 'mount': {}, |
vmikes | 37837f3 | 2017-01-09 10:19:51 +0100 | [diff] [blame] | 150 | 'swap': {}, |
Filip Pytloun | c8a001a | 2015-12-15 14:09:19 +0100 | [diff] [blame] | 151 | 'lvm': {}, |
Simon Pasquier | 375001e | 2017-01-26 13:22:33 +0100 | [diff] [blame] | 152 | 'loopback': {}, |
Ales Komarek | a634f4b | 2016-10-02 13:11:04 +0200 | [diff] [blame] | 153 | 'multipath': { |
| 154 | 'enabled': False, |
| 155 | 'pkgs': ['multipath-tools', 'multipath-tools-boot'], |
| 156 | 'service': 'multipath-tools' |
| 157 | }, |
Filip Pytloun | eaef6ec | 2015-12-15 18:39:28 +0100 | [diff] [blame] | 158 | 'lvm_pkgs': ['lvm2'], |
Filip Pytloun | f5383a4 | 2015-10-06 16:28:32 +0200 | [diff] [blame] | 159 | }, |
| 160 | 'RedHat': { |
| 161 | 'mount': {}, |
vmikes | 37837f3 | 2017-01-09 10:19:51 +0100 | [diff] [blame] | 162 | 'swap': {}, |
Filip Pytloun | c8a001a | 2015-12-15 14:09:19 +0100 | [diff] [blame] | 163 | 'lvm': {}, |
Simon Pasquier | 375001e | 2017-01-26 13:22:33 +0100 | [diff] [blame] | 164 | 'loopback': {}, |
Ales Komarek | a634f4b | 2016-10-02 13:11:04 +0200 | [diff] [blame] | 165 | 'multipath': { |
| 166 | 'enabled': False, |
| 167 | 'pkgs': [], |
| 168 | 'service': 'multipath' |
| 169 | }, |
Filip Pytloun | f5383a4 | 2015-10-06 16:28:32 +0200 | [diff] [blame] | 170 | }, |
| 171 | }, grain='os_family', merge=salt['pillar.get']('linux:storage')) %} |