Server

From Things and Stuff Wiki
Jump to navigation Jump to search


SSH

Handy

tmux

SSH keys

in ~/.ssh

ssh-keygen -t rsa -C "your_email@youremail.com"
cat id_rsa.pub

SCP

scp -P 8023 file.txt milk@thingsandstuff.org:~/file.txt

SSHFS

Rsync

  • Rsync over alt SSH port: --rsh='ssh -p8023'

Web

Nginx

Enable logging in vhost conf;

error_log /var/log/nginx-vhostnamehere.log error;

.htaccess

MediaWiki

MediaWiki:Sidebar

Backup

nice -n 19 mysqldump -u $USER --password=$PASSWORD $DATABASE -c | nice -n 19 gzip -9 > ~/backup/wiki-$DATABASE-$(date '+%Y%m%d').sql.gz

Other CMSs

Caching

Performance

Backup

Provision

Virtualisation

VirtualBox config;

  • Enable host Linux modules: vboxnetflt and vboxnetadp
  • Enable host-only adapter 'virtualbox0' in VB Preferences > Network if not previously enabled, then select in guest preferences
  • https://github.com/milkmiruku/boxbootstrap
  • Keep VM names lowercase and no spaces for easier command-line stuff

Provisioning VirtualBoxes for local dev work;

vagrant package --vagrantfile Vagrantfile.pkg --include README.txt
  stored in ~/.vagrant.d/boxes
vagrant box add lucid32 http://files.vagrantup.com/lucid32.box
vagrant box remove lucid32
vagrant box list

Filesystem

IaaS

Knowledge management

Video streaming

E-mail

Anti-spam;

Google Apps

Hosting