Skip to content

Instantly share code, notes, and snippets.

@abcarroll
Last active August 29, 2015 14:20
Show Gist options
  • Save abcarroll/ff8f7e5983f2e5b38573 to your computer and use it in GitHub Desktop.
Save abcarroll/ff8f7e5983f2e5b38573 to your computer and use it in GitHub Desktop.
Install LEMP, Postfix, and PowerDNS
#!/bin/bash
packages=(
# > > System utilities
netselect-apt sudo rcconf parted
# > > Internet Services, Programming
nginx
php5-fpm php5-cli
mysql-server
pdns-server
postfix
# > > Webserver related packages
# Database
php5-mysql php5-sqlite
# Encryption
php5-mcrypt php5-mhash
# Misc heavily used
php5-curl php5-gd
# Extras
php5-ffmpeg php5-tidy
# > Specialty (uncomment)
## Bindings for the libssh library
# php5-ssh2
## pspell module for php5
# php5-pspell
## Cyrus SASL Extension
# php5-sasl
## Image Manipulation
# php5-imagick
# php5-exactimage
## Memcached:
## memcached extension module for PHP5, uses libmemcached
# php5-memcached
## memcache extension module for PHP5
# php5-memcache
# > > Archiving Utilities
unzip unrar-free
# > > Cryptography Utilities
# cryptsetup
# > > Window Management
screen tmux
# > > Basic utitlities
bc beep vim wget links file less patch apache2-utils dnsutils ntp whois xz-utils
# > > Data transfer, clients
rsync git ftp lrzsz links
# > > System monitoring
htop iftop iotop sysstat iptraf
# > > More extras
hexedit nmap
# Specialty (uncomment)
# rabbitmq-server
# redis-server
# mongodb php5-mongo
# pdns-recursor
# squid
# xen-linux-system xen-tools
)
(apt-get install "${packages[@]}") && (echo "%staff ALL=(ALL) NOPASSWD: ALL" > /etc/sudoers.d/staff) && (chmod 644 /etc/sudoers.d/staff) && (dpkg-reconfigure sysstat)
chattr +a /root/.bash_history
chattr +a /root/.bash_profile
chattr +a /root/.bash_login
chattr +a /root/.profile
chattr +a /root/.bash_logout
chattr +a /root/.bashrc
echo "export PS1=\"\n# \[\e[0;37m\]\u@\h\[\e[00m\]; \[\e[0;33m\]\w\[\e[00m\]\n\[\e[0;32m\];\[\e[00m\] \"" >> /root/.bashrc
echo "set tabstop=2
set mouse=a
set autoindent
set history=100
set number
set ww=b,s,[,],<,>
set backspace=indent,eol,start
set laststatus=2
set confirm
set pastetoggle=<F11>
syntax on
highlight Comment ctermfg=grey" > .vimrc
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment