-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathinst-pi
51 lines (41 loc) · 1.66 KB
/
inst-pi
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
################################################################################
#!/usr/bin/bash
# Test to install all automatic on a Pi with Debian 9 Basic
# if wget is not working do a /// apt-get install ca-certificates
# wget https://raw.githubusercontent.com/syswombat/batch/master/inst-pi -O - > /tmp/inst-pi
# chmod +x /tmp/inst-pi
# run with inst-pi
# This file will run on my Network
#################################################################################
# add a Fix IP Address
wget https://raw.githubusercontent.com/syswombat/batch/master/snippets/pi-fix-ip -O - >> /etc/dhcpcd.conf
# change localhost and Host
# add the correct IP Address
mv /etc/hosts /etc/hosts.org
10.147.42.253 PI-Name > /etc/hosts
127.0.1.1 PI-Name >> /etc/hosts
mv /etc/hostname /etc/hostname.org
PI-Name > /etc/hostname
# add VIM and set number
apt install vim-nox -y
echo set number >> ~/.vimrc
# quick update and upgrade call up with
wget https://raw.githubusercontent.com/syswombat/batch/master/F-snippets/smart-Linux-update -O - >> /usr/local/bin/update
chmod +x /usr/local/bin/update
# add Fail2Ban for SSH
apt install fail2ban -y
wget https://raw.githubusercontent.com/syswombat/batch/master/F-snippets/jail.local -O - >> /etc/fail2ban/jail.local
# NTP Client and add local NTP Server
apt install -y NTP
mv /etc/ntp.conf /etc/ntp.conf.org
# add Munin Client
# don't forget to change the config in the Munin Master too
apt install -y munin-node munin-plugins-extra
echo allow ^10\.147\.42\.63$ >> /etc/munin/munin-node.conf
/etc/init.d/munin-node restart
### remove what you don't need
rm /etc/munin/plugins/test
munin-node-configure
/etc/init.d/munin-node restart
### reboot
reboot