View Apache caching
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<IfModule mod_expires.c> | |
ExpiresActive On | |
ExpiresDefault "access 7 days" | |
ExpiresByType application/javascript "access plus 1 year" | |
ExpiresByType text/javascript "access plus 1 year" | |
ExpiresByType text/css "access plus 1 year" | |
ExpiresByType text/html "access plus 7 day" | |
ExpiresByType text/x-javascript "access 1 year" | |
ExpiresByType image/gif "access plus 1 year" | |
ExpiresByType image/jpeg "access plus 1 year" |
View backup-all-databases.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
#create user for dump | |
#mysql> GRANT SHOW DATABASES, SELECT, LOCK TABLES, RELOAD ON *.* to dump@localhost IDENTIFIED BY 'dumppwd'; | |
#mysql> FLUSH PRIVILEGES; | |
BACKUP_PATH=/mnt/mysqlbackup/dump | |
# make backup directory | |
mkdir -p $BACKUP_PATH |
View varnish_wordpress
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
backend default { | |
.host = "127.0.0.1"; | |
.port = "8080"; | |
} | |
acl purge { | |
"127.0.0.1"; | |
"localhost"; | |
} |
View nginx.conf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
worker_processes auto; | |
events { | |
use epoll; | |
worker_connections 1024; | |
multi_accept on; | |
} | |
http { | |
include /etc/nginx/mime.types; | |
default_type application/octet-stream; |
View class skeleton
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# == Class: blah | |
# | |
# blahblahblah | |
# | |
# === Actions | |
# - blah | |
# - blah | |
# - blah | |
# | |
# === Examples |
View backup-databases.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
#create user for dump | |
#mysql> GRANT SHOW DATABASES, SELECT, LOCK TABLES, RELOAD ON *.* to dump@localhost IDENTIFIED BY 'dumppwd'; | |
#mysql> FLUSH PRIVILEGES; | |
BACKUP_PATH=/mnt/mysqlbackup/dump | |
DBASE[0]=base1 | |
DBASE[1]=base2 |
View Zabbix-CentOS-Client.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
rpm --import http://repo.zabbixzone.com/centos/RPM-GPG-KEY-zabbixzone | |
rpm -Uvh http://repo.zabbixzone.com/centos/zabbixzone-release-0.0-1.noarch.rpm | |
yum install zabbix-agent zabbix-sender |
View zabbixmon-mysql.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
GRANT USAGE ON *.* TO 'zabbixmon'@'localhost' IDENTIFIED BY 'superpassword'; | |
flush privileges; |
View send_lsws_stats.pl
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
# | |
# Get latest LiteSpeed Web Server stats | |
# | |
# somewhere from zabbix forums | |
# | |
# add to cron: | |
#* * * * * /etc/zabbix/scripts/send_lsws_stats.pl --host=client.com --server=server.com > /dev/null 2>&1 | |
# | |
use English '-no_match_vars'; |
View template_memcache.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<zabbix_export version="1.0" date="09.06.10" time="10.53"> | |
<hosts> | |
<host name="Template_Memcache"> | |
<proxy_hostid>0</proxy_hostid> | |
<useip>1</useip> | |
<dns></dns> | |
<ip>127.0.0.1</ip> | |
<port>10050</port> | |
<status>3</status> |
OlderNewer