Commit b03399a6 authored by david's avatar david 💬

cleaned up repo and started on something new

parent 7cb5c4f1
# .dotfiles
*vim, zsh and stuff*
*This repository holds various personal configs, homemade zsh plugins and random scripts. Go ahead and reuse.*
* [Installation](#installation)
* [ZSH plugins](#zsh-plugins)
## Installation
Here goes a online installer:
curl -xyz; bash
## ZSH plugins
* public ssh key deployment
* ubuntu prep script
- setup strong root password
* nice motd (+checks)
* snmp setup (for ubuntus, and else?)
* let's encrypt/getssl/dns verification/miab deployment
* fail2ban setup (for ssh on ubuntus, and else?)
* duplicity/backup deployment
- setup backup
- easy restore
- notification mails (only on error) -> [ ] make enterprise & relativity backup notification more silent
* openssh setup (for ubuntus and else?)
- set strong ciphers/methods (check!)
- disable PasswordAuthentication (check!)
- disable AllowRootLogin (check!)
- setup sshusers group and configure sshd accordingly (check! list users)
- deploy SSHFP DNS records to MIAB (check!)
- reset hostkeys (make secure hostkeys) (check for strong keys!)
- setup fail2ban for ssh (check?)
- make chroot for users easy
* miab post-install/-upgrade script
- script to disable owncloud/nextcloud in miab
- also maybe enforce dmarc (spf/dkim)
- patch -p 22 in backup script (or make a pr)
# this is just a collection of lines i used to install my new thinkpad
fdisk -ll
sudo fdisk /dev/sda
mkfs.ext4 /dev/sda1
sudo mount /dev/sda1 /mnt
pacman -Sy
pacstrap /mnt base zsh wget openssh curl htop nload bash-completion zsh sshuttle xorg-server i3 i3status dmenu vim firefox sudo grub
genfstab -p /mnt >> /mnt/etc/fstab
arch-chroot /mnt
vim /etc/hostname
vim /etc/hosts
ln -sf /usr/share/zoneinfo/Europe/Vienna /etc/localtime
vim /etc/locale.gen
echo en_US.UTF-8 > /etc/locale.conf
vim /etc/console.conf
mkinitcpio -p linux
# basic installer for my configs
# Basic installer for my personal dotfiles.
# vim, vifm, zsh, i3(for desktops)
# maybe also: powerline fonts, gnome-terminal and some terminal multiplexer
# author:
# license: MIT
# git:
#which host am i
#create links in ~ accordingly
echo "creating link for greywind"
# **** vars ****
timestamp=$(date +"%Y%m%d%H%M")
# **** functions ****
message() {
if [ $1 == "e" ]; then
elif [ $1 == "i" ]; then
elif [ $1 == "w" ]; then
elif [ $1 == "d" ]; then
if [ $debug -eq 1 ]; then
return 0
message e "Unknown message level[$1]."
return 1
echo -e [$level] ${@:2}
echo -e [$timestamp][$command][$1] ${@:2} >> $logfile
sleep 0.1
echo "what do you want me to do?"
read input
echo $input
failsafe() {
if [ $1 -ne 0 ]; then
message e "Installer died horribly!"
if [ $2 ]; then
message d "Dumping last output to logfile[$logfile] and stdout."
echo ${@:2} | tee -a $logfile
exit 1
# **** debugging/testing stuff ****
#rm -rf $root*
#ln -s $HOME/Git/dotfiles $root
# **** start of script ****
message d "Warming up dotfiles installer."
message d "Initiating preflight checks."
# check if logfile exists and is writeable, if not try to create it with failsafe
# check dependencies, try to install missing with failsafe
# (awk tee ls git wget/curl rm mv sleep date)
# check for preexisting data at install destination, get rid of it
if [ -h $root ]; then
link=$(ls -la $root | awk '{print $9" "$10" "$11}')
# It should be safe to just remove symbolic links because no data is actually deleted.
message d "Symbolic link exists at the install destination, attempting to remove it[$link]."
output=$(rm $root 2>&1); failsafe $? $output
message i "Removed symbolic link at the install destination."
elif [ -a $root ]; then
message d "Data exists at install destination, attempting to create a backup[$root.old.$timestamp]."
output=$(mv $root $root.old.$timestamp 2>&1); failsafe $? $output
message i "Created a backup of a preexisting folder at the install destination[$root.old.$timestamp]."
# clone dotfiles
message d "Attempting to clone git repository[$repo] into $root."
output=$(git clone $repo $root 2>&1); failsafe $? $output
message i "Cloned git repository into $root."
message d "Installer finished."
# **** end of script ****
# needed git repo
# software
_my software setup_
## resource setup
- archlinux
- Xorg
- some tiny login manager (autologin)
- i3, i3status, i3lock, dmenu, feh
- some terminal (maybe gnome-terminal)
- zsh, oh-my-zsh, vim, powerline
- sshuttle
- multimc
- vlc
- git
- mumble
- some filemanager (nautilus/vifm/pcmanfm)
- some image viewer (the gnome thing is fine)
- firefox, chrome, chromium
- openssh (server & client)
- infinality fonts
- gtk theme
- .. to be continued
## random tool
- htop
- nload
- tshark / wireshark-cli
- powertop
## what needs?
Host defiant
KexAlgorithms +diffie-hellman-group1-sha1
HostkeyAlgorithms ssh-dss
Host valiant
KexAlgorithms +diffie-hellman-group1-sha1
HostkeyAlgorithms ssh-dss
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment