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