Merge branch 'installSeperation'
commit
8ff574d424
@ -0,0 +1,12 @@
|
|||||||
|
# ADAR
|
||||||
|
|
||||||
|
Aney's Debian Auto Ricer
|
||||||
|
|
||||||
|
## Why
|
||||||
|
|
||||||
|
Because I forget what I like to install, and maybe I can get some friends, etc. to use debian this way.
|
||||||
|
|
||||||
|
## Todo
|
||||||
|
|
||||||
|
- Make it so it's not specifically tailored for me.
|
||||||
|
- Maybe create it's own git repo (make sense for a multi-person script)
|
||||||
@ -0,0 +1,51 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# Aney's Debian Auto Ricer
|
||||||
|
# Downloads the rest of my scripties, and runs what is wanted
|
||||||
|
# Currently needs to be hosted on a server (done so that I can test)
|
||||||
|
# i.e. Basic install, Server, Desktop nogui, Desktop gui,
|
||||||
|
|
||||||
|
SERVER="192.168.1.112/debian"
|
||||||
|
INSTALL_TYPE=""
|
||||||
|
|
||||||
|
# If the user isn't root. Don't run.
|
||||||
|
if [[ $EUID -ne 0 ]]; then
|
||||||
|
echo "This script must be run as root"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ $1 == "server"] || [ $1 == "desktop" ]
|
||||||
|
then
|
||||||
|
$INSTALL_TYPE = $1
|
||||||
|
else
|
||||||
|
$INSTALL_TYPE = "desktop"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Download the scripts
|
||||||
|
# TODO: Install scripts from git
|
||||||
|
#apt install git
|
||||||
|
#git clone https://github.com/aney/scripts/
|
||||||
|
# Delete the git repo that was created
|
||||||
|
|
||||||
|
mkdir adar_scripts
|
||||||
|
|
||||||
|
wget -O adar_scripts/debian_base.sh $SERVER/debian_base.sh
|
||||||
|
if [ $INSTALL_TYPE == "server" ]
|
||||||
|
then
|
||||||
|
wget -O adar_scripts/debian_server.sh $SERVER/debian_server.sh
|
||||||
|
else
|
||||||
|
wget -O adar_scripts/debian_desktop.sh $SERVER/debian_desktop.sh
|
||||||
|
wget -O adar_scripts/debian_gui.sh $SERVER/debian_gui.sh
|
||||||
|
wget -O adar_scripts/debian_unfinished.sh $SERVER/debian_unfinished.sh
|
||||||
|
fi
|
||||||
|
|
||||||
|
bash adar_scripts/debian_base.sh
|
||||||
|
if [ $INSTALL_TYPE == "server" ]
|
||||||
|
then
|
||||||
|
bash adar_scripts/debian_server.sh
|
||||||
|
else
|
||||||
|
bash adar_scripts/debian_desktop.sh
|
||||||
|
bash adar_scripts/debian_gui.sh
|
||||||
|
bash adar_scripts/debian_unfinished.sh
|
||||||
|
fi
|
||||||
|
|
||||||
@ -0,0 +1,71 @@
|
|||||||
|
# This install script is for a debian based distro
|
||||||
|
# Ideally a minimal install (No GUI, or tools installed)
|
||||||
|
|
||||||
|
# This install will install only tools for CLI use
|
||||||
|
# The idea is to have GUI, etc. seperated then called in one 'master' script
|
||||||
|
|
||||||
|
# Update and Upgrade the system first
|
||||||
|
apt update && apt upgrade -y
|
||||||
|
|
||||||
|
# Install essential tools required for other installs
|
||||||
|
apt install sudo build-essential ssh -y
|
||||||
|
|
||||||
|
# Make the user a sudoer (If passed to the script)
|
||||||
|
adduser nathan sudo
|
||||||
|
|
||||||
|
# Network Installs
|
||||||
|
apt install network-manager -y
|
||||||
|
|
||||||
|
# System Utilities
|
||||||
|
apt install perl wget curl man -y
|
||||||
|
|
||||||
|
# Make the terminal usable*
|
||||||
|
apt install tmux zsh -y
|
||||||
|
|
||||||
|
## Text Editors
|
||||||
|
apt install vim neovim -y
|
||||||
|
apt install groff -y
|
||||||
|
|
||||||
|
## Git
|
||||||
|
apt install git tig -y
|
||||||
|
|
||||||
|
# Compression Utilities
|
||||||
|
apt install gzip zip tar bzip2 unrar -y
|
||||||
|
|
||||||
|
# Install terminal system utilities
|
||||||
|
apt install neofetch htop -y
|
||||||
|
|
||||||
|
# Backups
|
||||||
|
apt install rsync rdiff-backup -y
|
||||||
|
|
||||||
|
# VPN
|
||||||
|
apt install openvpn -y
|
||||||
|
|
||||||
|
HOME=/home/nathan/
|
||||||
|
# lf file manager
|
||||||
|
sudo -H -u nathan bash -c "mkdir $HOME/.local $HOME/.local/bin"
|
||||||
|
sudo -H -u nathan bash -c "curl -LO https://github.com/gokcehan/lf/releases/latest/download/lf-linux-amd64.tar.gz | tar -xf -C $HOME/.local/bin"
|
||||||
|
|
||||||
|
# Vi mode terminal and local bin
|
||||||
|
# This also happens in dotfiles, so kinda redundant
|
||||||
|
echo "set -o vi\nexport PATH=\$HOME/.local/bin:\$PATH" >> .zshrc
|
||||||
|
echo "export PATH=\$HOME/.local/bin/*:\$PATH" >> .zshrc
|
||||||
|
# Add to path for this session
|
||||||
|
export PATH=\$HOME/.local/bin/:$PATH
|
||||||
|
export PATH=\$HOME/.local/bin/dmenu:$PATH
|
||||||
|
|
||||||
|
# *Make the terminal usable
|
||||||
|
## Change default shell to zsh
|
||||||
|
chsh nathan -s /bin/zsh
|
||||||
|
|
||||||
|
## Oh my Zsh
|
||||||
|
sudo -H -u nathan bash -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" "" --unattended
|
||||||
|
|
||||||
|
# Firewall
|
||||||
|
apt install ufw -y
|
||||||
|
systemctl --now enable ufw
|
||||||
|
ufw enable
|
||||||
|
ufw default deny incoming
|
||||||
|
ufw default allow incoming
|
||||||
|
ufw allow 22 # Allow SSH
|
||||||
|
|
||||||
@ -0,0 +1,45 @@
|
|||||||
|
# This install script is for a debian based distro
|
||||||
|
# It is assumed that it's a minimal install, with at least debian_base
|
||||||
|
# This will install additional utilities that make debain usable without a GUI
|
||||||
|
|
||||||
|
# Download and install debian_base?
|
||||||
|
|
||||||
|
# Additional filesystem utilities
|
||||||
|
## For mounting samba/cif drives, and MTP (mobile phones)
|
||||||
|
apt install cifs-utils jmtpfs -y
|
||||||
|
|
||||||
|
## Audio
|
||||||
|
apt install alsa-utils alsa-oss pulseaudio -y
|
||||||
|
|
||||||
|
# Bluetooth
|
||||||
|
apt install blueman -y
|
||||||
|
|
||||||
|
# Music Player (daemon, and utilities)
|
||||||
|
apt install mpd mpc mcmpcpp -y
|
||||||
|
|
||||||
|
# RSS Reader
|
||||||
|
apt install newsboat -y
|
||||||
|
|
||||||
|
# Mail Client
|
||||||
|
apt install neomutt -y
|
||||||
|
|
||||||
|
# Groff
|
||||||
|
apt install groff -y
|
||||||
|
|
||||||
|
# Download Utilities (Legallity, uncertain)
|
||||||
|
## Youtube-dl
|
||||||
|
curl -L https://yt-dl.org/downloads/latest/youtube-dl -o /usr/local/bin/youtube-dl
|
||||||
|
chmod a+rx /usr/local/bin/youtube-dl
|
||||||
|
|
||||||
|
## Torrenting (Seperate script?)
|
||||||
|
apt install transmission-daemon transmission-cli transmission-remote-cli -y
|
||||||
|
#systemctl stop transmission-daemon.service
|
||||||
|
#/lib/systemd/system/tranmission-daemon.service # Change debian-transmission to $USER
|
||||||
|
# systemctl daemon-reload
|
||||||
|
# start/restart service
|
||||||
|
# /etc/transmission-daemon/settings.json # edit whitelist, blocklist, password
|
||||||
|
# Setup the user for transmission-daemon
|
||||||
|
|
||||||
|
# Xanmod Kernel (It makes desktops better, servers not so much)
|
||||||
|
echo 'deb http://deb.xanmod.org releases main' | sudo tee /etc/apt/sources.list.d/xanmod-kernel.list && wget -qO - https://dl.xanmod.org/gpg.key | sudo apt-key add -
|
||||||
|
apt update && apt install linux-xanmod -y
|
||||||
@ -0,0 +1,58 @@
|
|||||||
|
# This install script is for a debian based distro
|
||||||
|
# It is assumed that it's a minimal install, with no GUI
|
||||||
|
|
||||||
|
# This install will install a GUI, and graphical programs
|
||||||
|
# It is to be called from a 'master' script, to install what you need
|
||||||
|
|
||||||
|
# Install essentials that may not have been installed prior
|
||||||
|
apt install sudo xorg build-essential -y
|
||||||
|
|
||||||
|
# Pulseaudio GUI
|
||||||
|
apt install pavucontrol -y
|
||||||
|
|
||||||
|
# Email
|
||||||
|
apt install thunderbird -y
|
||||||
|
|
||||||
|
# File Manager
|
||||||
|
apt install nemo -y
|
||||||
|
|
||||||
|
# Video Player
|
||||||
|
apt install mpv -y
|
||||||
|
|
||||||
|
# Screencap and screenshots
|
||||||
|
apt install ffmpeg maim slop -y
|
||||||
|
|
||||||
|
## Keypress capture
|
||||||
|
apt install screenkey -y
|
||||||
|
|
||||||
|
# Image viewer, PDF Reader
|
||||||
|
apt install feh zathura -y
|
||||||
|
|
||||||
|
# Web Browsers
|
||||||
|
apt install firefox-esr -y
|
||||||
|
## Brave (Potentiall removing)
|
||||||
|
apt install apt-transport-https -y
|
||||||
|
curl -s https://brave-browser-apt-release.s3.brave.com/brave-core.asc | sudo apt-key --keyring /etc/apt/trusted.gpg.d/brave-browser-release.gpg add -
|
||||||
|
echo "deb [arch=amd64] https://brave-browser-apt-release.s3.brave.com/ stable main" | sudo tee /etc/apt/sources.list.d/brave-browser-release.list
|
||||||
|
apt update
|
||||||
|
apt install brave-browser -y
|
||||||
|
|
||||||
|
# Media tools
|
||||||
|
apt install gimp -y
|
||||||
|
|
||||||
|
# Multimonitor
|
||||||
|
apt install arandr -y
|
||||||
|
|
||||||
|
# Suckless pre-requisites
|
||||||
|
apt install libx11-dev libxft-dev libxinerama-dev -y
|
||||||
|
apt install libx11-xcb-dev libxcb-res0-dev -y
|
||||||
|
|
||||||
|
# Notifications
|
||||||
|
apt install dunst libnotify-bin -y
|
||||||
|
|
||||||
|
# Virtualisation
|
||||||
|
apt install qemu-kvm libvirt-clients libvirt-daemon-system virt-manager -y
|
||||||
|
# Add to virtualisation groups
|
||||||
|
adduser nathan libvirt
|
||||||
|
adduser nathan libvirt-qemu
|
||||||
|
|
||||||
@ -0,0 +1,8 @@
|
|||||||
|
# This install script is for a debian based distro
|
||||||
|
# It's assumed that it's a minimal install with at least debian_base
|
||||||
|
|
||||||
|
# Download and install debian_base?
|
||||||
|
|
||||||
|
# Network Monitoring
|
||||||
|
apt install bmon nload
|
||||||
|
|
||||||
@ -0,0 +1,76 @@
|
|||||||
|
# Fake user installs
|
||||||
|
userdo() {
|
||||||
|
sudo -H -u nathan bash -c "$1"
|
||||||
|
}
|
||||||
|
|
||||||
|
# User
|
||||||
|
#su nathan
|
||||||
|
HOME=/home/nathan
|
||||||
|
|
||||||
|
mkdir2() {
|
||||||
|
for DIR
|
||||||
|
do
|
||||||
|
if [ ! -d $DIR ]; then
|
||||||
|
mkdir $DIR
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
|
# Create directories
|
||||||
|
sudo -H -u nathan bash -c "cd ~"
|
||||||
|
mkdir2 books/ documents/ downloads/ misc/ music/ pictures/ recordings/ video/
|
||||||
|
touch recordings/.recording_status
|
||||||
|
|
||||||
|
# Temp, so startx works
|
||||||
|
echo "exec dwm" > $HOME/.xinitrc
|
||||||
|
|
||||||
|
# Set location to download source code and other repos
|
||||||
|
REPO=$HOME/agitrepo
|
||||||
|
sudo -H -u nathan bash -c "mkdir $REPO"
|
||||||
|
|
||||||
|
# Suckless installs
|
||||||
|
# Not sure how to do the intsall without sudo prompt...
|
||||||
|
# dwm
|
||||||
|
sudo -H -u nathan bash -c "git clone https://git.suckless.org/dwm $REPO/adwm"
|
||||||
|
cd $REPO/adwm/
|
||||||
|
make clean install
|
||||||
|
|
||||||
|
# st terminal
|
||||||
|
sudo -H -u nathan bash -c "git clone https://git.suckless.org/st $REPO/ast"
|
||||||
|
cd $REPO/ast/
|
||||||
|
make clean install
|
||||||
|
|
||||||
|
# dmenu launcher
|
||||||
|
sudo -H -u nathan bash -c "git clone https://git.suckless.org/dmenu $REPO/admenu"
|
||||||
|
cd $REPO/admenu/
|
||||||
|
make clean install
|
||||||
|
|
||||||
|
# slstatus
|
||||||
|
sudo -H -u nathan bash -c "git clone https://git.suckless.org/slstatus $REPO/aslstatus"
|
||||||
|
cd $REPO/aslstatus/
|
||||||
|
make clean install
|
||||||
|
|
||||||
|
# Setup the bin directory for custom scripts
|
||||||
|
sudo -H -u nathan bash -c "mkdir $HOME/.local/bin"
|
||||||
|
# Vi mode terminal and local bin # This also happens in dotfiles, so kinda redundant
|
||||||
|
echo "set -o vi\nexport PATH=\$HOME/.local/bin:\$PATH" >> .zshrc
|
||||||
|
echo "export PATH=\$HOME/.local/bin/*:\$PATH" >> .zshrc
|
||||||
|
# Add to path for this session
|
||||||
|
export PATH=\$HOME/.local/bin/:$PATH
|
||||||
|
export PATH=\$HOME/.local/bin/dmenu:$PATH
|
||||||
|
|
||||||
|
# Muh scripties
|
||||||
|
sudo -H -u nathan bash -c "git clone https://github.com/aney/scripts $REPO/ascripts/"
|
||||||
|
# create a sym link. Will change to cp if others start using my install.sh
|
||||||
|
ln -s $REPO/ascripts/dmenu/ $HOME/.local/bin/
|
||||||
|
ln -s $REPO/ascripts/config/ $HOME/.local/bin/
|
||||||
|
ln -s $REPO/ascripts/backup/ $HOME/.local/bin/
|
||||||
|
|
||||||
|
# dotfiles
|
||||||
|
# This will overwrite existing dotfiles...
|
||||||
|
sudo -H -u nathan bash -c "git clone https://github.com/aney/dotfiles $REPO/adotfiles/"
|
||||||
|
ln -s $REPO/adotfiles/.[^.]* $HOME
|
||||||
|
|
||||||
|
# Extras. Bg image, icons, etc. Put an image in the git repo/server when done
|
||||||
|
#sudo -H -u nathan bash -c "$(curl 'https://pixabay.com/get/57e8d7414c51aa14f6d1867dda3536781539dbe35552754b_1920.jpg' $HOME/pictures/wallpapers/barren.jpg)"
|
||||||
|
|
||||||
Loading…
Reference in New Issue