forked from szepeviktor/debian-server-tools
-
Notifications
You must be signed in to change notification settings - Fork 0
/
server.yml
189 lines (173 loc) · 4.83 KB
/
server.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
---
# Server datasheet
system:
fqdn: #host.example.com
os: "Debian “stretch”"
install-date: #YYYY-MM-DD
# tput sgr0;for C in {1..7};do tput setaf $C;echo -n "■${C}■ ";tput sgr0;done;echo
host-color: 7
trespass-warning: "Ez a szerver A/AZ-CÉG használatában áll. Másoknak a belépés tilos."
#trespass-warning: "This server is used by COMPANY. Unauthorized entry is prohibited."
storage-provider: #"Amazon S3"
mail-provider: #"SparkPost"
# Package settings
package:
apt:
# See /package/apt-sources/
sources:
- sury-php
- nodejs
- percona
- szepeviktor
ca-certificates:
# http://metadata.ftp-master.debian.org/changelogs/main/c/ca-certificates/testing_changelog
install-testing: true
adduser:
firstuser:
name: viktor
ssh-key: "ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBJnaM2JLvO4DWkmmSXys+jn0KhTRVkCfAAhv/1Pszs0DJTheQgOR9e3ThNCgR7CxIqZ5kXrZ+BIDtDs5IGrg9IA= szv-ecdsa"
openssh-server:
port: #222 (preferably under 1024)
fail2ban:
sender: #[email protected]
apache2:
prg-http-user: #user
prg-http-pwd: #secret
prg-ssl-cn: #prg.1.2.3.4.xip.io
mod_ratelimit: disabled
# Mail server reputation
mail-server:
monitoring:
- http://www.projecthoneypot.org/
- https://mxtoolbox.com/
- https://www.rblmon.com/accounts/register/
- https://rbltracker.com/
registered:
- https://www.dnswl.org/selfservice/
- https://postmaster.google.com/
- https://postmaster.live.com/snds/
- https://ers.trendmicro.com/reputations/global_approved_list
# Custom data directories
cruft:
- /usr/share/locale
- /usr/share/man
- /home
- /root
- /etc/php/7.0
- /var/lib/php/modules
- /usr/local/bin
- /usr/local/sbin
- /usr/local/src
- /usr/local/lib/node_modules
- /usr/local/lib/python2.7
- /usr/local/lib/python3.4
- /var/lib/mysql
- /var/log
# cruft $(shyaml get-values cruft < /root/server.yml | xargs -n 1 echo " --ignore ") > cruft.log
# Clients using this server
clients:
#"Client Name":
# type: user account|empty domain|email account|cron job|SeoPanel|Piwik|OWA|website|mailman|mirror
# services:
# - service 1
# - service 2
# Services provided by this server
services:
private:
#"service name 1":
# type: daemon|login script|cron job
# transport: tcp/123|php-ext|vhost|uds|name-service
# source: non-packaged|non-repo
# location: /path/dir
# description: text
#"service name 2":
# type: daemon
# transport: tcp/443
# description: vhost.name
irqbalance:
type: daemon
fail2ban:
type: daemon
transport: uds
suhosin:
type: php-ext
source: non-packaged
description: /usr/lib/php5/20121212
mod-pagespeed:
# daemon or Apache module?
drush:
source: composer
location: /opt/drush
courier-mta:
type: daemon
transport: [ tcp/25, tcp/465, tcp/587 ]
spamassassin:
type: daemon
transport: tcp/783
monit:
type: daemon
transport: uds
vmwaretools:
transport: VMCI socket
description: Virtual Machine Communication Interface
unattended-upgrades:
type: cron job
unscd:
type: daemon
transport: name service
mariadb:
type: daemon
transport: [ tcp/3306, uds ]
php7.0-fpm:
type: daemon
transport: uds
syslog-errors:
type: cron job
public:
munin-node:
type: daemon
transport: tcp/4949
apache2:
type: daemon
transport: [ tcp/80, tcp/443 ]
can-send-email:
type: vhost
description: PHP script
# Package management
packaging:
apt:
list-command: dpkg -l
location: /
pip2:
list-command: pip2 list
location: /usr/local/lib/python2.7
pip3:
list-command: pip3 list
location: /usr/local/lib/python3.4
# PEAR + PECL
pear:
list-command: pear list-channels && pear list -c CHANNEL && pear list -c pecl.php.net
location: /usr/share/php
node:
list-command: npm -g ls
location: /usr/lib/node_modules
ruby:
list-command: gem list
location: /usr/lib/ruby/vendor_ruby
remarks: |
Some remarks.
Other remarks.
teardown:
- Notify users
- Email accounts
- RELAYCLIENT on the smarthost
- DNS resolver access
- Remove from whitelists, postmaster tools, RBL monitors
- Revoke SSL certificates
- Remove from healthchecks.io and remote monitoring
- Remove DNS records
- Remove PTR record
- Cancel domain registration
# YAML editor: http://yaml-online-parser.appspot.com/
# shyaml get-value < server.yml
...